SPARK-1905 Attach token to api header C#

This commit is contained in:
Eric Harding committed 2018-11-30 11:22:31 -05:00
1 parent c6b494db16
commit 3bbef9f328
3 files changed
+4 -3

No files matched your search

+2 -2
View File
@@ -32,6 +32,7 @@ namespace bts.api.core {
}
public AuthToken token { get; private set; }
public string user { get; private set; }
public async Task<bool> login(string username, string password) {
var auth_service = locate<AuthService>();
@@ -41,8 +42,7 @@ namespace bts.api.core {
});
if (result.success) {
token = result.value.Token;
// todo
// ApiNativeMethods.set_token(...)
user = username;
return true;
}
return false;