I have a problem with my nano arduino and the nrf24l01 as receiver
radio.read() does not return a value.  You can't assign "no value" to a boolean.

If radio.available() is true then radio.read() will succeed. There is no need to test if it worked or not.