I am getting a request from mobile app. They are sending a variable
In Ruby everything is truthy except for
false. Thus both
1 are truthy - you will never reach the
else part with this set up.
So in your case you want to check exactly for
if isbookmarked == 1 do something elsif isbookmarked == 0 do something end