These errors shouldn't be logged =)

This commit is contained in:
Samuel Georges 2015-08-07 19:28:59 +10:00
parent 0cd0dc5b62
commit aa2722b0a0
1 changed files with 2 additions and 1 deletions

View File

@ -1,6 +1,7 @@
<?php namespace October\Demo\Components;
use Cms\Classes\ComponentBase;
use ApplicationException;
class Todo extends ComponentBase
{
@ -32,7 +33,7 @@ class Todo extends ComponentBase
$items = post('items', []);
if (count($items) >= $this->property('max')) {
throw new \Exception(sprintf('Sorry only %s items are allowed.', $this->property('max')));
throw new ApplicationException(sprintf('Sorry only %s items are allowed.', $this->property('max')));
}
if (($newItem = post('newItem')) != '') {