Skip to content
This repository has been archived by the owner on Dec 28, 2023. It is now read-only.

Commit

Permalink
Develop (#215)
Browse files Browse the repository at this point in the history
* fixed

* fixed

* fixed test

* fixed code and tests

* updated for `php-tools` `1.2.8`

* come back

* come back

* fixed cells type hinting

* added new line

* fixed templates

* updated

* fixed templates

* fixed sorting of static pages

* Develop win2 (#213)

fixed for windows

* fixed

* fixed for sniffer

* fixed

* fixed for sniffer

* some fixes

* some fixes

* fixed namespace

* fixed bug

* fixed

* fixed

* fixed for sniffer

* added some i18n constants

* `debug_kit` package no longer required, only suggested

* `add` and` edit` templates for `Posts` and` Pages` have been merged into the
    `form` templates respectively

* fixed bug

* fixed tests

* added empty line

* renamed method

* fixed code

* fixed

* fixed templates

* `add` and` edit` template files for `Posts`, `PostsCategories`, ` Pages` and
    `PagesCategories` have been merged into the `form` templates respectively

* fixed template

* fixed common templates

* fixed

* fixed tabs

* fixed bug

* fixed

* added `admin/priority-badge` template element

* fixed tabs

* updated

* fixed bug for some no existing photos

* updated

* `mcrypt` is no longer required

* added a basic style sheet for printing

* fixed for sniffer

* updated for `me-tools` `2.18.11`

* fixed

* fixed

* fixed

* fixed

* improved code for `PostsTable::queryForRelated()` method

* fixed

* fixed for lower dependencies
  • Loading branch information
mirko-pagliai authored Aug 22, 2019
1 parent 7200188 commit 7f597f7
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 9 deletions.
10 changes: 5 additions & 5 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@
"donatj/phpuseragentparser": "*",
"enyo/dropzone": "^5.1",
"league/commonmark": "^0.18",
"mirko-pagliai/cakephp-database-backup": "^2.5",
"mirko-pagliai/cakephp-database-backup": "^2.6.1",
"mirko-pagliai/cakephp-entity-file-log": "^1.0",
"mirko-pagliai/cakephp-recaptcha-mailhide": "^1.2",
"mirko-pagliai/cakephp-recaptcha-mailhide": "^1.2.2",
"mirko-pagliai/cakephp-stop-spam": "^1.0.2",
"mirko-pagliai/cakephp-thumber": "^1.5.2",
"mirko-pagliai/cakephp-thumber": "^1.7.1",
"mirko-pagliai/cakephp-tokens": "^1.2",
"mirko-pagliai/me-tools": "^2.18.11",
"mirko-pagliai/php-tools": "^1.2.8",
Expand All @@ -27,8 +27,8 @@
},
"require-dev": {
"cakephp/cakephp-codesniffer": "^3.0",
"mirko-pagliai/cakephp-assets": "^1.3",
"phpunit/phpunit": "^5.7|^6.0"
"mirko-pagliai/cakephp-assets": "^1.4.1",
"phpunit/phpunit": "^5.7.14|^6.0"
},
"suggest": {
"cakephp/debug_kit": "Debug Toolbar for CakePHP applications",
Expand Down
4 changes: 3 additions & 1 deletion src/Utility/StaticPage.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,9 @@ protected static function getAllPaths()
$paths = array_merge($paths, self::getPaths($plugin));
}

return array_filter($paths, 'file_exists');
return array_clean(array_map(function ($path) {
return rtrim($path, DS);
}, $paths), 'file_exists');
}, 'static_pages');
}

Expand Down
6 changes: 3 additions & 3 deletions tests/TestCase/Utility/StaticPageTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -148,9 +148,9 @@ public function testGetAllPaths()
{
$this->loadPlugins(['TestPlugin']);
$result = $this->invokeMethod(StaticPage::class, 'getAllPaths');
$this->assertContains(APP . 'Template' . DS . 'StaticPages' . DS, $result);
$this->assertContains(ROOT . 'src' . DS . 'Template' . DS . 'StaticPages' . DS, $result);
$this->assertContains(Plugin::path('TestPlugin') . 'src' . DS . 'Template' . DS . 'StaticPages' . DS, $result);
$this->assertContains(APP . 'Template' . DS . 'StaticPages', $result);
$this->assertContains(ROOT . 'src' . DS . 'Template' . DS . 'StaticPages', $result);
$this->assertContains(Plugin::path('TestPlugin') . 'src' . DS . 'Template' . DS . 'StaticPages', $result);
$this->assertEquals(Cache::read('paths', 'static_pages'), $result);
}

Expand Down

0 comments on commit 7f597f7

Please sign in to comment.