Completed
Push — 1.4.0 ( 4bf4ac...f3e04e )
by Sylver
04:49
created

ext   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 17
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 3
c 1
b 0
f 0
dl 0
loc 17
rs 10
wmc 2

1 Method

Rating   Name   Duplication   Size   Complexity  
A is_enableable() 0 5 2
1
<?php
2
/**
3
 *
4
 * @package		Breizh Smilies Categories Extension
5
 * @copyright	(c) 2020-2021 Sylver35  https://breizhcode.com
6
 * @license		http://opensource.org/licenses/gpl-license.php GNU Public License
7
 *
8
 */
9
10
namespace sylver35\smiliescat;
11
12
/**
13
* @ignore
14
*/
15
16
/**
17
 * Class ext
18
 *
19
 */
20
class ext extends \phpbb\extension\base
21
{
22
	/**
23
	 * Check whether or not the extension can be enabled.
24
	 * The current phpBB version should meet or exceed
25
	 * the minimum version required by this extension:
26
	 *
27
	 * Requires phpBB 3.3.4 and PHP 7.1.3
28
	 *
29
	 * @return bool
30
	 * @access public
31
	 */
32
	public function is_enableable()
33
	{
34
		$config = $this->container->get('config');
35
36
		return phpbb_version_compare($config['version'], '3.3.4', '>=') && version_compare(PHP_VERSION, '7.1.3', '>=');
37
	}
38
}
39