1 | <?php |
||
21 | class Push implements PushInterface |
||
22 | { |
||
23 | const BASE_CHAT_URL = 'https://api.flowdock.com/v1/messages/chat'; |
||
24 | const BASE_TEAM_INBOX_URL = 'https://api.flowdock.com/v1/messages/team_inbox'; |
||
25 | |||
26 | /** |
||
27 | * @var string |
||
28 | */ |
||
29 | private $flowApiToken; |
||
30 | |||
31 | /** |
||
32 | * Constructor |
||
33 | * |
||
34 | * @param string $flowApiToken A flow API token |
||
35 | */ |
||
36 | public function __construct($flowApiToken) |
||
40 | |||
41 | /** |
||
42 | * {@inheritdoc} |
||
43 | */ |
||
44 | public function sendChatMessage(ChatMessageInterface $message, array $options = array()) |
||
48 | |||
49 | /** |
||
50 | * {@inheritdoc} |
||
51 | */ |
||
52 | public function sendTeamInboxMessage(TeamInboxMessageInterface $message, array $options = array()) |
||
56 | |||
57 | /** |
||
58 | * Sends a message to a flow |
||
59 | * |
||
60 | * @param BaseMessageInterface $message A message instance to send |
||
61 | * @param string $baseUrl A base URL |
||
62 | * @param array $options An array of options used by request |
||
63 | * |
||
64 | * @return boolean |
||
65 | */ |
||
66 | protected function sendMessage(BaseMessageInterface $message, $baseUrl, array $options = array()) |
||
81 | |||
82 | /** |
||
83 | * Creates a client to interact with Flowdock API |
||
84 | * |
||
85 | * @param string $url |
||
86 | * |
||
87 | * @return Client |
||
88 | */ |
||
89 | protected function createClient($url) |
||
93 | } |
||
94 |
It seems like the type of the argument is not accepted by the function/method which you are calling.
In some cases, in particular if PHP’s automatic type-juggling kicks in this might be fine. In other cases, however this might be a bug.
We suggest to add an explicit type cast like in the following example: