Added login check method
Code cleaning
Fixed logout url