| Conditions | 1 |
| Paths | 1 |
| Total Lines | 19 |
| Code Lines | 12 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 60 | public function finalize() |
||
| 61 | { |
||
| 62 | $payload = [ |
||
| 63 | 'text' => $this->text, |
||
| 64 | 'link_names' => true, |
||
| 65 | 'unfurl_links' => true, |
||
| 66 | 'unfurl_media' => true, |
||
| 67 | 'mrkdwn' => true, |
||
| 68 | 'response_type' => $this->responseType, |
||
| 69 | ]; |
||
| 70 | |||
| 71 | $payload['attachments'] = $this->attachments; |
||
| 72 | |||
| 73 | $this->headers->set('Content-Type', 'application/json'); |
||
| 74 | |||
| 75 | $this->setContent(json_encode($payload)); |
||
| 76 | |||
| 77 | return $this; |
||
| 78 | } |
||
| 79 | } |
||
| 80 |