![]() Server : Apache System : Linux server2.corals.io 4.18.0-348.2.1.el8_5.x86_64 #1 SMP Mon Nov 15 09:17:08 EST 2021 x86_64 User : corals ( 1002) PHP Version : 7.4.33 Disable Function : exec,passthru,shell_exec,system Directory : /home/corals/job-board.corals.io/Corals/modules/SMS/Hooks/ |
<?php namespace Corals\Modules\SMS\Hooks; use Corals\Modules\SMS\Models\Message; class MessageableTrait { function getPhoneNumber() { return function () { if (!is_null($phoneNumber = $this->phone_number)) { return $phoneNumber; } if (!is_null($phone = $this->phone)) { return $phone; } return null; }; } function messages() { return function () { return $this->morphMany(Message::class, 'messageable'); }; } function routeNotificationForNexmo() { return function () { return $this->getPhoneNumber(); }; } function routeNotificationForTwilio() { return function () { return $this->getPhoneNumber(); }; } function getSMSBodyParameters() { return function () { return []; }; } static function getSMSBodyDescriptions() { return function () { return []; }; } }