fixed return value of loggedinuser call