adding support for migrated users

Code adds support for users migrated from previous ding-versions. Depends on alma_user_authenticate function returning user_id value in it's return value, see https://github.com/ding2tal/alma/pull/12