You've already forked AstralRinth
forked from didirus/AstralRinth
General cleanup: fix some bugs, some refactoring (#65)
* Merged mod file upload in version creation, mod creation and
version file add to one function; This makes sure that they are
consistent
* Made some fields on `User` optional: `github_id`, `avatar_url`, `bio`.
* We may not want to publicly show the `github_id` to everyone
with access to the API
* If we allow non-github users, some of those fields would be
invalid; some oauth providers may not have avatars or bios
* Made CORS origins should configurable
* Made `--reconfigure-indices` and `--reset-indices` exit after
completion instead of starting the server
This commit is contained in:
@@ -182,12 +182,12 @@ pub async fn auth_callback(
|
||||
|
||||
User {
|
||||
id: user_id,
|
||||
github_id: user.id as i64,
|
||||
github_id: Some(user.id as i64),
|
||||
username: user.login,
|
||||
name: user.name,
|
||||
email: user.email,
|
||||
avatar_url: user.avatar_url,
|
||||
bio: user.bio,
|
||||
avatar_url: Some(user.avatar_url),
|
||||
bio: Some(user.bio),
|
||||
created: Utc::now(),
|
||||
role: Role::Developer.to_string(),
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user