Skip to content

Commit a8ae112

Browse files
authored
Merge pull request #1557 from spryker/bugfix/php-74-fixes
Small fixes for PHP 7.4
2 parents 101d865 + 4c45713 commit a8ae112

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
lines changed

src/Propel/Generator/Builder/Om/QueryBuilder.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -533,10 +533,10 @@ protected function addFindPk(&$script)
533533
foreach ($pks as $col) {
534534
$colNames[]= '$' . $col->getName();
535535
}
536-
$pkType = 'array['. join($colNames, ', ') . ']';
536+
$pkType = 'array['. join(', ', $colNames) . ']';
537537
$script .= "
538538
* <code>
539-
* \$obj = \$c->findPk(array(" . join($examplePk, ', ') . "), \$con);";
539+
* \$obj = \$c->findPk(array(" . join(', ', $examplePk) . "), \$con);";
540540
} else {
541541
$pkType = 'mixed';
542542
$script .= "

src/Propel/Generator/Builder/Util/SchemaReader.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,7 @@ public function startElement($parser, $name, $attributes)
187187
$this->isForReferenceOnly = (null !== $isForRefOnly ? ('true' === strtolower($isForRefOnly)) : true); // defaults to TRUE
188188
}
189189

190-
if ('/' !== $xmlFile{0}) {
190+
if ('/' !== $xmlFile[0]) {
191191
$xmlFile = realpath(dirname($this->currentXmlFile) . DIRECTORY_SEPARATOR . $xmlFile);
192192
if (!file_exists($xmlFile)) {
193193
throw new SchemaException(sprintf('Unknown include external "%s"', $xmlFile));
@@ -202,12 +202,12 @@ public function startElement($parser, $name, $attributes)
202202
break;
203203

204204
case 'table':
205-
if (!isset($attributes['schema'])
205+
if (!isset($attributes['schema'])
206206
&& $this->currDB->getSchema() && $this->currDB->getPlatform()->supportsSchemas()
207207
&& false === strpos($attributes['name'], $this->currDB->getPlatform()->getSchemaDelimiter())) {
208208
$attributes['schema'] = $this->currDB->getSchema();
209209
}
210-
210+
211211
$this->currTable = $this->currDB->addTable($attributes);
212212
if ($this->isExternalSchema()) {
213213
$this->currTable->setForReferenceOnly($this->isForReferenceOnly);

src/Propel/Runtime/ActiveQuery/Criteria.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2408,10 +2408,10 @@ public function doUpdate($updateValues, ConnectionInterface $con)
24082408
$rawcvt = '';
24092409
// parse the $params['raw'] for ? chars
24102410
for ($r = 0, $len = strlen($raw); $r < $len; $r++) {
2411-
if ($raw{$r} == '?') {
2411+
if ($raw[$r] == '?') {
24122412
$rawcvt .= ':p'.$p++;
24132413
} else {
2414-
$rawcvt .= $raw{$r};
2414+
$rawcvt .= $raw[$r];
24152415
}
24162416
}
24172417
$sql .= $rawcvt . ', ';

0 commit comments

Comments
 (0)