mirror of
https://github.com/flextype/flextype.git
synced 2025-08-10 07:06:45 +02:00
feat(core): Flextype Solid Core - next round #458
This commit is contained in:
@@ -29,7 +29,7 @@ class Cors
|
||||
*/
|
||||
public function __construct($flextype)
|
||||
{
|
||||
$this->app = $flextype;
|
||||
$this->flextype = $flextype;
|
||||
$this->container = $flextype->getContainer();
|
||||
}
|
||||
|
||||
@@ -44,11 +44,11 @@ class Cors
|
||||
return;
|
||||
}
|
||||
|
||||
$this->app->options('/{routes:.+}', function ($request, $response) {
|
||||
$this->flextype->options('/{routes:.+}', function ($request, $response) {
|
||||
return $response;
|
||||
});
|
||||
|
||||
$this->app->add(function ($req, $res, $next) use ($container) {
|
||||
$this->flextype->add(function ($req, $res, $next) use ($container) {
|
||||
$response = $next($req, $res);
|
||||
|
||||
// Set variables
|
||||
|
@@ -86,7 +86,7 @@ class Entries
|
||||
*/
|
||||
public function __construct($flextype)
|
||||
{
|
||||
$this->app = $flextype;
|
||||
$this->flextype = $flextype;
|
||||
$this->container = $flextype->getContainer();
|
||||
}
|
||||
|
||||
|
@@ -60,7 +60,7 @@ class MediaFiles
|
||||
*/
|
||||
public function __construct($flextype)
|
||||
{
|
||||
$this->app = $flextype;
|
||||
$this->flextype = $flextype;
|
||||
$this->container = $flextype->getContainer();
|
||||
}
|
||||
|
||||
|
@@ -31,7 +31,7 @@ class MediaFilesMeta
|
||||
*/
|
||||
public function __construct($flextype)
|
||||
{
|
||||
$this->app = $flextype;
|
||||
$this->flextype = $flextype;
|
||||
$this->container = $flextype->getContainer();
|
||||
}
|
||||
|
||||
|
@@ -34,7 +34,7 @@ class MediaFolders
|
||||
*/
|
||||
public function __construct($flextype)
|
||||
{
|
||||
$this->app = $flextype;
|
||||
$this->flextype = $flextype;
|
||||
$this->container = $flextype->getContainer();
|
||||
}
|
||||
|
||||
|
@@ -28,7 +28,7 @@ class MediaFoldersMeta
|
||||
*/
|
||||
public function __construct($flextype)
|
||||
{
|
||||
$this->app = $flextype;
|
||||
$this->flextype = $flextype;
|
||||
$this->container = $flextype->getContainer();
|
||||
}
|
||||
|
||||
|
@@ -48,7 +48,7 @@ class Plugins
|
||||
*/
|
||||
public function __construct($flextype)
|
||||
{
|
||||
$this->app = $flextype;
|
||||
$this->flextype = $flextype;
|
||||
$this->container = $flextype->getContainer();
|
||||
$this->locales = $this->container['yaml']->decode(Filesystem::read(ROOT_DIR . '/src/flextype/locales.yaml'));
|
||||
}
|
||||
|
@@ -35,7 +35,7 @@ class Markdown
|
||||
*/
|
||||
public function __construct($flextype, $markdown)
|
||||
{
|
||||
$this->app = $flextype;
|
||||
$this->flextype = $flextype;
|
||||
$this->container = $flextype->getContainer();
|
||||
$this->markdown = $markdown;
|
||||
}
|
||||
|
@@ -35,7 +35,7 @@ class Shortcode
|
||||
*/
|
||||
public function __construct($flextype, $shortcode)
|
||||
{
|
||||
$this->app = $flextype;
|
||||
$this->flextype = $flextype;
|
||||
$this->container = $flextype->getContainer();
|
||||
$this->shortcode = $shortcode;
|
||||
}
|
||||
|
@@ -38,7 +38,7 @@ class Frontmatter
|
||||
*/
|
||||
public function __construct($flextype)
|
||||
{
|
||||
$this->app = $flextype;
|
||||
$this->flextype = $flextype;
|
||||
$this->container = $flextype->getContainer();
|
||||
}
|
||||
|
||||
|
@@ -44,7 +44,7 @@ class Json
|
||||
*/
|
||||
public function __construct($flextype)
|
||||
{
|
||||
$this->app = $flextype;
|
||||
$this->flextype = $flextype;
|
||||
$this->container = $flextype->getContainer();
|
||||
}
|
||||
|
||||
|
@@ -49,7 +49,7 @@ class Yaml
|
||||
*/
|
||||
public function __construct($flextype)
|
||||
{
|
||||
$this->app = $flextype;
|
||||
$this->flextype = $flextype;
|
||||
$this->container = $flextype->getContainer();
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user