Skip to content

Commit 293d175

Browse files
Merge pull request #392 from symfony-cmf/fix_reload
Fix reload
2 parents 047db66 + bf2194d commit 293d175

File tree

5 files changed

+11
-8
lines changed

5 files changed

+11
-8
lines changed

.platform.app.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ web:
4444

4545
cron:
4646
symfony:
47-
spec: '0 1 * * *'
47+
spec: '* */2 * * *'
4848
cmd: |
4949
# force clearing the cache
5050
rm -rf app/cache/prod

src/AppBundle/DataFixtures/PHPCR/LoadStaticPageData.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ public function load(ObjectManager $manager)
7979
$page->setBody($overview['body']);
8080
}
8181

82-
if (isset($overview['publishable']) && $overview['publishable'] === false) {
82+
if (isset($overview['publishable']) && false === $overview['publishable']) {
8383
$page->setPublishable(false);
8484
}
8585

@@ -180,13 +180,13 @@ private function loadBlock(ObjectManager $manager, $parent, $name, $block)
180180
$manager->persist($document);
181181
}
182182

183-
if ($className == 'Symfony\Cmf\Bundle\BlockBundle\Doctrine\Phpcr\ReferenceBlock') {
183+
if ('Symfony\Cmf\Bundle\BlockBundle\Doctrine\Phpcr\ReferenceBlock' == $className) {
184184
$referencedBlock = $manager->find(null, $block['referencedBlock']);
185185
if (null === $referencedBlock) {
186186
throw new \Exception('did not find '.$block['referencedBlock']);
187187
}
188188
$document->setReferencedBlock($referencedBlock);
189-
} elseif ($className == 'Symfony\Cmf\Bundle\BlockBundle\Doctrine\Phpcr\ActionBlock') {
189+
} elseif ('Symfony\Cmf\Bundle\BlockBundle\Doctrine\Phpcr\ActionBlock' == $className) {
190190
$document->setActionName($block['actionName']);
191191
}
192192

tests/Functional/AdminTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ protected function doTestReachableAdminRoutes($admin)
111111

112112
// do not test POST routes
113113
if (isset($requirements['_method'])) {
114-
if ($requirements['_method'] != 'GET') {
114+
if ('GET' != $requirements['_method']) {
115115
continue;
116116
}
117117
}

web/app_dev.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
// Feel free to remove this, extend it, or make something more sophisticated.
2222
if (isset($_SERVER['HTTP_CLIENT_IP'])
2323
|| isset($_SERVER['HTTP_X_FORWARDED_FOR'])
24-
|| !(in_array(@$_SERVER['REMOTE_ADDR'], ['127.0.0.1', 'fe80::1', '::1']) || php_sapi_name() === 'cli-server')
24+
|| !(in_array(@$_SERVER['REMOTE_ADDR'], ['127.0.0.1', 'fe80::1', '::1']) || 'cli-server' === php_sapi_name())
2525
) {
2626
header('HTTP/1.0 403 Forbidden');
2727
exit('You are not allowed to access this file. Check '.basename(__FILE__).' for more information.');

web/reload-fixtures.php

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,5 +18,8 @@ function runCommand($command)
1818
}
1919
}
2020

21-
runCommand(__DIR__.'/../bin/console cache:clear -e=prod');
22-
runCommand(__DIR__.'/../bin/console -v doctrine:phpcr:fixtures:load -e=prod');
21+
runCommand('rm -rf app/cache/prod');
22+
runCommand(__DIR__.'/../bin/console --env=prod doctrine:phpcr:init:dbal --drop --force');
23+
runCommand(__DIR__.'/../bin/console --env=prod doctrine:phpcr:repository:init');
24+
runCommand(__DIR__.'/../bin/console -v --env=prod doctrine:phpcr:fixtures:load -n');
25+
runCommand(__DIR__.'/../bin/console --env=prod cache:warmup -n --no-debug');

0 commit comments

Comments
 (0)