Completed
Pull Request — master (#17)
by
unknown
01:48
created

ReactionModel   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 16
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 2

Importance

Changes 0
Metric Value
wmc 1
c 0
b 0
f 0
lcom 1
cbo 2
dl 0
loc 16
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A saveReaction() 0 4 1
1
<?php
2
/**
3
 * This Driver is based entirely on official documentation of the Mattermost Web
4
 * Services API and you can extend it by following the directives of the documentation.
5
 *
6
 * For the full copyright and license information, please read the LICENSE.txt
7
 * file that was distributed with this source code. For the full list of
8
 * contributors, visit https://github.com/gnello/php-mattermost-driver/contributors
9
 *
10
 * God bless this mess.
11
 *
12
 * @author Bruno Spyckerelle <[email protected]>
13
 * @link https://api.mattermost.com/
14
 */
15
16
namespace Gnello\Mattermost\Models;
17
18
/**
19
 * Class ReactionModel
20
 *
21
 * @package Gnello\Mattermost\Models
22
 */
23
class ReactionModel extends AbstractModel
24
{
25
    /**
26
     * @var string
27
     */
28
    public static $endpoint = '/reactions';
29
30
    /**
31
     * @param array $requestOptions
32
     * @return \Psr\Http\Message\ResponseInterface
33
     */
34
    public function saveReaction(array $requestOptions)
35
    {
36
        return $this->client->post(self::$endpoint, $requestOptions);
37
    }
38
}
39