modified version of angular-devise for klaseko