@@ -147,9 +147,8 @@ public async Task<RedirectResult> TwitchLogin([FromQuery] string code, [FromServ
147
147
/// <returns>
148
148
/// A redirect to the nullinside website.
149
149
/// Errors:
150
- /// 2 = Internal error generating token.
151
- /// 3 = Code was invalid
152
- /// 4 = Twitch account has no email
150
+ /// 1 = Internal error
151
+ /// 2 = Error with twitch
153
152
/// </returns>
154
153
[ AllowAnonymous ]
155
154
[ HttpGet ]
@@ -160,12 +159,12 @@ public async Task<RedirectResult> TwitchStreamingToolsLogin([FromQuery] string c
160
159
// credentials question we're being asked.
161
160
string ? siteUrl = _configuration . GetValue < string > ( "Api:SiteUrl" ) ;
162
161
if ( ! _webSockets . WebSockets . ContainsKey ( state ) ) {
163
- return Redirect ( $ "{ siteUrl } /user/login/desktop?error=2 ") ;
162
+ return Redirect ( $ "{ siteUrl } /user/login/desktop?error=1 ") ;
164
163
}
165
164
166
165
// Since someone already warned us this request was coming, create an oauth token from the code we received.
167
166
if ( null == await api . CreateAccessToken ( code , token ) ) {
168
- return Redirect ( $ "{ siteUrl } /user/login/desktop?error=3 ") ;
167
+ return Redirect ( $ "{ siteUrl } /user/login/desktop?error=2 ") ;
169
168
}
170
169
171
170
// The "someone" that warned us this request was coming has been sitting around waiting for an answer on a web
@@ -184,7 +183,7 @@ public async Task<RedirectResult> TwitchStreamingToolsLogin([FromQuery] string c
184
183
socket . Dispose ( ) ;
185
184
}
186
185
catch {
187
- return Redirect ( $ "{ siteUrl } /user/login/desktop?error=2 ") ;
186
+ return Redirect ( $ "{ siteUrl } /user/login/desktop?error=1 ") ;
188
187
}
189
188
190
189
return Redirect ( $ "{ siteUrl } /user/login/desktop") ;
0 commit comments