DeleteTrait::delete()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 2
nc 1
nop 0
dl 0
loc 3
rs 10
c 0
b 0
f 0
1
<?php
2
3
namespace Helix\Asana\Base\AbstractEntity;
4
5
use Helix\Asana\Base\AbstractEntity;
6
7
/**
8
 * Adds `delete()` to entities.
9
 *
10
 * @mixin AbstractEntity
11
 */
12
trait DeleteTrait {
13
14
    /**
15
     * `DELETE`
16
     */
17
    public function delete (): void {
18
        $this->api->delete($this);
19
        $this->api->getPool()->remove($this->getPoolKeys());
20
    }
21
}