Hello,
if (verify_login_id = Login.where(params[:email_address], “active”
=>1).select(‘id’)# => [#<Login id: 767>]
verify_admin_id = Admin.where(“login_id” =>
verify_login_id.first.id).exists? #=> true)
statement
else
raise(ActiveRecord::RecordNotFound.new(“Authorization is required to
access
this endpoint!”))
end
Syntax correct?