added loging/out case for result controller