[sty]
This commit is contained in:
parent
49b9481701
commit
002e057d45
|
|
@ -65,12 +65,15 @@ namespace _zeitbild.api
|
|||
}),
|
||||
"restriction": () => restriction_none,
|
||||
"execution": () => async ({"input": input}) => {
|
||||
if (input === null) {
|
||||
if (input === null)
|
||||
{
|
||||
return Promise.reject(new Error("impossible"));
|
||||
}
|
||||
else {
|
||||
else
|
||||
{
|
||||
const passed : boolean = await _zeitbild.service.auth_internal.check(input.name, input.password);
|
||||
if (! passed) {
|
||||
if (! passed)
|
||||
{
|
||||
return Promise.resolve({
|
||||
"status_code": 403,
|
||||
"data": null,
|
||||
|
|
|
|||
|
|
@ -43,10 +43,12 @@ namespace _zeitbild.api
|
|||
"execution": async (stuff) => {
|
||||
const session : {key : string; value : lib_plankton.session.type_session} = await session_from_stuff(stuff);
|
||||
await lib_plankton.session.end(session.key);
|
||||
return Promise.resolve({
|
||||
return Promise.resolve(
|
||||
{
|
||||
"status_code": 200,
|
||||
"data": null,
|
||||
});
|
||||
}
|
||||
);
|
||||
},
|
||||
}
|
||||
);
|
||||
|
|
|
|||
Loading…
Reference in a new issue