1
0
Fork 0
mirror of https://git.rwth-aachen.de/acs/public/villas/web/ synced 2025-03-09 00:00:01 +01:00

change authenticate endpoints

This commit is contained in:
irismarie 2021-02-05 14:52:21 +01:00
parent b8b0f3e44a
commit cf8a1e049c

View file

@ -26,7 +26,7 @@ class UsersDataManager extends RestDataManager {
login(username, password) {
if (username && password) {
RestAPI.post(this.makeURL('/authenticate'), { username: username, password: password }).then(response => {
RestAPI.post(this.makeURL('/authenticate/internal'), { username: username, password: password }).then(response => {
AppDispatcher.dispatch({
type: 'users/logged-in',
token: response.token,
@ -39,7 +39,7 @@ class UsersDataManager extends RestDataManager {
});
});
} else { // external authentication
RestAPI.post(this.makeURL('/authenticate'),).then(response => {
RestAPI.post(this.makeURL('/authenticate/external'),).then(response => {
AppDispatcher.dispatch({
type: 'users/logged-in',
token: response.token,