You defined a method named logged_in
which take no arguments but you are calling it with 1 argument:
if logged_in(false)
You should be doing:
if logged_in
Your code should probably look like this:
def logged_in
current_user
end
def login_required
return false if logged_in
redirect_to log_in_path
end