summaryrefslogtreecommitdiff
path: root/app/Report/ReportParserGenerate.php
diff options
context:
space:
mode:
authorGreg Roach <fisharebest@webtrees.net>2018-11-17 15:22:08 +0000
committerGreg Roach <fisharebest@webtrees.net>2018-11-18 18:18:42 +0000
commit8d0ebef0d075981bd943e8256e2c81a3b1e92b4b (patch)
tree6ce584137d2125125417a6c749d5d5e9a11611f1 /app/Report/ReportParserGenerate.php
parentada1c84947c5c97bcc08a94582e9443f18df3d13 (diff)
downloadwebtrees-8d0ebef0d075981bd943e8256e2c81a3b1e92b4b.tar.gz
webtrees-8d0ebef0d075981bd943e8256e2c81a3b1e92b4b.tar.bz2
webtrees-8d0ebef0d075981bd943e8256e2c81a3b1e92b4b.zip
Prefer class-constants to global-constants
Diffstat (limited to 'app/Report/ReportParserGenerate.php')
-rw-r--r--app/Report/ReportParserGenerate.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/app/Report/ReportParserGenerate.php b/app/Report/ReportParserGenerate.php
index 3eee391d0e..5f636f7165 100644
--- a/app/Report/ReportParserGenerate.php
+++ b/app/Report/ReportParserGenerate.php
@@ -24,6 +24,7 @@ use Fisharebest\Webtrees\Family;
use Fisharebest\Webtrees\Filter;
use Fisharebest\Webtrees\Functions\Functions;
use Fisharebest\Webtrees\Functions\FunctionsDate;
+use Fisharebest\Webtrees\Gedcom;
use Fisharebest\Webtrees\GedcomRecord;
use Fisharebest\Webtrees\GedcomTag;
use Fisharebest\Webtrees\I18N;
@@ -35,7 +36,6 @@ use Fisharebest\Webtrees\Place;
use Fisharebest\Webtrees\Tree;
use stdClass;
use Symfony\Component\Cache\Adapter\NullAdapter;
-use Symfony\Component\ExpressionLanguage\ExpressionFunction;
use Symfony\Component\ExpressionLanguage\ExpressionLanguage;
/**
@@ -1108,7 +1108,7 @@ class ReportParserGenerate extends ReportParserBase
$i++;
// Privacy check - is this a link, and are we allowed to view the linked object?
$subrecord = Functions::getSubRecord($level, "$level $t", $subrec, $i);
- if (preg_match('/^\d ' . WT_REGEX_TAG . ' @(' . WT_REGEX_XREF . ')@/', $subrecord, $xref_match)) {
+ if (preg_match('/^\d ' . Gedcom::REGEX_TAG . ' @(' . Gedcom::REGEX_XREF . ')@/', $subrecord, $xref_match)) {
$linked_object = GedcomRecord::getInstance($xref_match[1], $this->tree);
if ($linked_object && !$linked_object->canShow()) {
continue;
@@ -1530,7 +1530,7 @@ class ReportParserGenerate extends ReportParserBase
$level++;
$value = $this->getGedcomValue($id, $level, $this->gedrec);
}
- $value = preg_replace('/^@(' . WT_REGEX_XREF . ')@$/', '$1', $value);
+ $value = preg_replace('/^@(' . Gedcom::REGEX_XREF . ')@$/', '$1', $value);
$value = '"' . addslashes($value) . '"';
}
$condition = str_replace("@$id", $value, $condition);