Adding metadata handling to User model