Added last login tracking

A Fix for issue #876