Replace macro with equivalent function call

Also removed useless bool return