Skip to content

Commit

Permalink
fix bugs found by scrunitizer
Browse files Browse the repository at this point in the history
  • Loading branch information
ivanbarlog committed Jan 6, 2018
1 parent d78e5ee commit e129d03
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 37 deletions.
4 changes: 3 additions & 1 deletion composer.json
Expand Up @@ -10,11 +10,13 @@
"require": {
"php": "^7.1",
"everlutionsk/ajaxcom-php": "^1.1",
"symfony/framework-bundle": "^3.0|~4.0",
"symfony/http-foundation": "^3.0|~4.0",
"symfony/routing": "^3.0|~4.0",
"symfony/config": "^3.0|~4.0",
"symfony/dependency-injection": "^3.0|~4.0",
"symfony/http-kernel": "^3.0|~4.0",
"symfony/templating": "^3.0|~4.0"
"symfony/twig-bundle": "^3.0|~4.0"
},
"license": "MIT",
"authors": [
Expand Down
2 changes: 2 additions & 0 deletions src/Controller/AjaxcomTrait.php
Expand Up @@ -60,4 +60,6 @@ protected function doNotChangeUrl(): self

return $this;
}

abstract protected function get($id);
}
36 changes: 0 additions & 36 deletions src/Service/Ajaxcom.php
Expand Up @@ -5,7 +5,6 @@
namespace Everlution\AjaxcomBundle\Service;

use Everlution\Ajaxcom\Handler;
use Everlution\AjaxcomBundle\DataObject\Callback as AjaxCallback;
use Everlution\AjaxcomBundle\Mutation\MutatorInterface;
use Everlution\AjaxcomBundle\Mutation\RenderableInterface;
use Everlution\AjaxcomBundle\Mutation\Container;
Expand Down Expand Up @@ -46,39 +45,4 @@ public function handle(string $view, array $parameters = []): JsonResponse

return new JsonResponse($this->handler->respond(), JsonResponse::HTTP_OK, self::AJAX_COM_CACHE_CONTROL);
}

public function renderBlock(string $id): self
{
$this->addBlocks->add($id);

return $this;
}

public function removeBlock(string $selector): self
{
$this->removeBlocks->add($selector);

return $this;
}

public function addCallback(AjaxCallback $callback): self
{
$this->callbacks->add($callback);

return $this;
}

public function replaceClass(string $selector, string $class): self
{
$this->replaceClass->add($selector, $class);

return $this;
}

public function doNotChangeUrl(): self
{
$this->changeUrl->doNotChangeUrl();

return $this;
}
}

0 comments on commit e129d03

Please sign in to comment.