diff options
Diffstat (limited to 'lib/data/rest_ds.dart')
-rw-r--r-- | lib/data/rest_ds.dart | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/data/rest_ds.dart b/lib/data/rest_ds.dart index 7d66d4a..36a82c7 100644 --- a/lib/data/rest_ds.dart +++ b/lib/data/rest_ds.dart @@ -6,11 +6,11 @@ import 'package:beam_messenger/models/user.dart'; class RestDatasource { NetworkUtil _netUtil = new NetworkUtil(); - static final BASE_URL = "http://192.168.0.74:8000"; - static final LOGIN_URL = BASE_URL + "/login"; + static final baseUrl = "http://192.168.0.74:8000"; + static final loginUrl = baseUrl + "/login"; Future<User> login(String email, String password) { - return _netUtil.post(LOGIN_URL, + return _netUtil.post(loginUrl, body: {"email": email, "password": password}).then((dynamic res) { print(res.toString()); if (res["status"]) throw new Exception(res["message"]); |