Fixed issue when logging using social account