fix warning
added register method
getToken the method was modified to perform the requested with get