Workaround sqlite query issues

Signed-off-by: Julius Härtl <jus@bitgrid.net>
This commit is contained in:
Julius Härtl
2021-04-13 17:07:57 +02:00
parent 9970ebc220
commit 990659b8f0
3 changed files with 45 additions and 35 deletions

View File

@@ -36,7 +36,7 @@ class AQueryParameter {
protected $value;
public function getValue() {
if (is_string($this->value)) {
if (is_string($this->value) && mb_strlen($this->value) > 1) {
$param = ($this->value[0] === '"' && $this->value[mb_strlen($this->value) - 1] === '"') ? mb_substr($this->value, 1, -1): $this->value;
return $param;
}