|
@@ 323-325 (lines=3) @@
|
| 320 |
|
|
| 321 |
|
// CSRF check |
| 322 |
|
$token = SecurityToken::inst(); |
| 323 |
|
if (empty($vars[$token->getName()]) || !$token->check($vars[$token->getName()])) { |
| 324 |
|
return new HTTPResponse(null, 400); |
| 325 |
|
} |
| 326 |
|
|
| 327 |
|
if (!isset($vars['ids']) || !$vars['ids']) { |
| 328 |
|
return (new HTTPResponse(json_encode(['status' => 'error']), 400)) |
|
@@ 369-371 (lines=3) @@
|
| 366 |
|
|
| 367 |
|
// CSRF check |
| 368 |
|
$token = SecurityToken::inst(); |
| 369 |
|
if (empty($data[$token->getName()]) || !$token->check($data[$token->getName()])) { |
| 370 |
|
return new HTTPResponse(null, 400); |
| 371 |
|
} |
| 372 |
|
|
| 373 |
|
// Check parent record |
| 374 |
|
/** @var Folder $parentRecord */ |
|
@@ 448-450 (lines=3) @@
|
| 445 |
|
|
| 446 |
|
// CSRF check |
| 447 |
|
$token = SecurityToken::inst(); |
| 448 |
|
if (empty($data[$token->getName()]) || !$token->check($data[$token->getName()])) { |
| 449 |
|
return new HTTPResponse(null, 400); |
| 450 |
|
} |
| 451 |
|
|
| 452 |
|
// Check parent record |
| 453 |
|
/** @var Folder $parentRecord */ |
|
@@ 612-614 (lines=3) @@
|
| 609 |
|
|
| 610 |
|
// CSRF check |
| 611 |
|
$token = SecurityToken::inst(); |
| 612 |
|
if (empty($data[$token->getName()]) || !$token->check($data[$token->getName()])) { |
| 613 |
|
return new HTTPResponse(null, 400); |
| 614 |
|
} |
| 615 |
|
|
| 616 |
|
// check addchildren permissions |
| 617 |
|
/** @var Folder $parentRecord */ |