diff --git a/src/Kdyby/Doctrine/Geo/Element.php b/src/Kdyby/Doctrine/Geo/Element.php index c7625be8..2b1dd987 100644 --- a/src/Kdyby/Doctrine/Geo/Element.php +++ b/src/Kdyby/Doctrine/Geo/Element.php @@ -244,7 +244,7 @@ protected function init() $separator = $this->separator; $coordsSeparator = $this->coordsSeparator; - $coordsRegexp = '~^\s*[\d\.]+\s*' . preg_quote($coordsSeparator) . '\s*[\d\.]+\s*$~i'; + $coordsRegexp = '~^\s*-?[\d\.]+\s*' . preg_quote($coordsSeparator) . '\s*-?[\d\.]+\s*$~i'; $coordinates = []; foreach (explode($separator, $coordsList) as $coords) {