diff options
author | crupest <crupest@outlook.com> | 2019-04-30 19:49:27 +0800 |
---|---|---|
committer | crupest <crupest@outlook.com> | 2019-04-30 19:49:27 +0800 |
commit | 484f59f9c954fdced635c24c5ab49840c3022d93 (patch) | |
tree | f695f1c3d7eb33554784c77dca4afde7f4227503 /Timeline/Entities/Http/User.cs | |
parent | e48e5f8d6e0b675493bceb8e26a957da050d282d (diff) | |
download | timeline-484f59f9c954fdced635c24c5ab49840c3022d93.tar.gz timeline-484f59f9c954fdced635c24c5ab49840c3022d93.tar.bz2 timeline-484f59f9c954fdced635c24c5ab49840c3022d93.zip |
Add avatar upload function.
Diffstat (limited to 'Timeline/Entities/Http/User.cs')
-rw-r--r-- | Timeline/Entities/Http/User.cs | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/Timeline/Entities/Http/User.cs b/Timeline/Entities/Http/User.cs index d42ca088..31cafaa3 100644 --- a/Timeline/Entities/Http/User.cs +++ b/Timeline/Entities/Http/User.cs @@ -40,4 +40,15 @@ public static ReturnCodeMessageResponse BadOldPassword { get; } = new ReturnCodeMessageResponse(BadOldPasswordCode, "Old password is wrong."); public static ReturnCodeMessageResponse NotExists { get; } = new ReturnCodeMessageResponse(NotExistsCode, "Username does not exists, please update token."); } + + public static class PutAvatarResponse + { + public const int SuccessCode = 0; + public const int ForbiddenCode = 1; + public const int NotExistsCode = 2; + + public static ReturnCodeMessageResponse Success {get;} = new ReturnCodeMessageResponse(SuccessCode, "Success to upload avatar."); + public static ReturnCodeMessageResponse Forbidden {get;} = new ReturnCodeMessageResponse(ForbiddenCode, "You are not allowed to upload the user's avatar."); + public static ReturnCodeMessageResponse NotExists {get;} = new ReturnCodeMessageResponse(NotExistsCode, "The username does not exists. If you are a user, try update your token."); + } } |