2024-03-05 13:18:57 +01:00
|
|
|
import { restGet, restPost } from './restConsumer.js'
|
|
|
|
|
|
|
|
export async function login(user, pass, exp){
|
2024-03-05 14:58:56 +01:00
|
|
|
return restPost("/login", {login: user, password: pass, expiration: exp});
|
|
|
|
}
|
|
|
|
|
|
|
|
export async function register(user, pass, mail){
|
|
|
|
return restPost("/user", {name: user, password: pass, mail: mail});
|
2024-03-05 13:18:57 +01:00
|
|
|
restPost("/login", {login: user, password: pass, expiration: exp})
|
2024-03-05 13:18:57 +01:00
|
|
|
}
|