Check for timestamp granularity

Fixes #5
This commit is contained in:
Sebastian Meyer 2022-07-01 15:33:25 +02:00
parent 3d4c65dba7
commit 02f2df679b
1 changed files with 5 additions and 0 deletions

View File

@ -193,6 +193,11 @@ class Server {
$this->errors[] = new Exception('badArgument'); $this->errors[] = new Exception('badArgument');
} }
} }
if (isset($this->args['from']) && isset($this->args['until'])) {
if (strlen($this->args['from']) !== strlen($this->args['until'])) {
$this->errors[] = new Exception('badArgument');
}
}
if (isset($this->args['set'])) { if (isset($this->args['set'])) {
$this->errors[] = new Exception('noSetHierarchy'); $this->errors[] = new Exception('noSetHierarchy');
} }