Removed incrementer from non-asset event listeners

This commit is contained in:
snipe 2017-08-23 13:59:59 -07:00
parent f35f8477d3
commit a5870c888e
4 changed files with 4 additions and 18 deletions

View file

@ -28,8 +28,7 @@ class AccessoryObserver
/**
* Listen to the Accessory created event, and increment
* the next_auto_tag_base value in the settings table when i
* Listen to the Accessory created event when
* a new accessory is created.
*
* @param Accessory $accessory
@ -37,9 +36,6 @@ class AccessoryObserver
*/
public function created(Accessory $accessory)
{
$settings = Setting::first();
$settings->increment('next_auto_tag_base');
$logAction = new Actionlog();
$logAction->item_type = Accessory::class;
$logAction->item_id = $accessory->id;

View file

@ -28,8 +28,7 @@ class ComponentObserver
/**
* Listen to the Component created event, and increment
* the next_auto_tag_base value in the settings table when i
* Listen to the Component created event when
* a new component is created.
*
* @param Component $component
@ -37,9 +36,6 @@ class ComponentObserver
*/
public function created(Component $component)
{
$settings = Setting::first();
$settings->increment('next_auto_tag_base');
$logAction = new Actionlog();
$logAction->item_type = Component::class;
$logAction->item_id = $component->id;

View file

@ -28,8 +28,7 @@ class ConsumableObserver
/**
* Listen to the Consumable created event, and increment
* the next_auto_tag_base value in the settings table when i
* Listen to the Consumable created event when
* a new consumable is created.
*
* @param Consumable $consumable
@ -37,8 +36,6 @@ class ConsumableObserver
*/
public function created(Consumable $consumable)
{
$settings = Setting::first();
$settings->increment('next_auto_tag_base');
$logAction = new Actionlog();
$logAction->item_type = Consumable::class;

View file

@ -28,8 +28,7 @@ class LicenseObserver
/**
* Listen to the License created event, and increment
* the next_auto_tag_base value in the settings table when i
* Listen to the License created event when
* a new license is created.
*
* @param License $license
@ -37,8 +36,6 @@ class LicenseObserver
*/
public function created(License $license)
{
$settings = Setting::first();
$settings->increment('next_auto_tag_base');
$logAction = new Actionlog();
$logAction->item_type = License::class;