Changed getting Facebook authentication from server-side to client-side