| Conditions | 4 |
| Paths | 4 |
| Total Lines | 17 |
| Code Lines | 14 |
| Lines | 0 |
| Ratio | 0 % |
| 1 | <?php |
||
| 29 | public function process() { |
||
| 30 | if ($target = $this->getObject()) { |
||
| 31 | if ($this->publishType == 'publish') { |
||
| 32 | $target->setIsPublishJobRunning(true); |
||
| 33 | $target->PublishOnDate = ''; |
||
| 34 | $target->writeWithoutVersion(); |
||
| 35 | $target->doPublish(); |
||
| 36 | } else if ($this->publishType == 'unpublish') { |
||
| 37 | $target->setIsPublishJobRunning(true); |
||
| 38 | $target->UnPublishOnDate = ''; |
||
| 39 | $target->writeWithoutVersion(); |
||
| 40 | $target->doUnpublish(); |
||
| 41 | } |
||
| 42 | } |
||
| 43 | $this->currentStep = 1; |
||
| 44 | $this->isComplete = true; |
||
| 45 | } |
||
| 46 | |||
| 47 | } |
You can fix this by adding a namespace to your class:
When choosing a vendor namespace, try to pick something that is not too generic to avoid conflicts with other libraries.