created last logged in function

also started work on giving policies userID’s