Fixing regenerate_user