These results are based on our legacy PHP analysis, consider migrating to our new PHP analysis engine instead. Learn more
1 | <?php |
||
2 | /** |
||
3 | * UIX WordPress Plugin |
||
4 | * |
||
5 | * @package uix |
||
6 | * @author David Cramer |
||
7 | * @license GPL-2.0+ |
||
8 | * @link |
||
9 | * @copyright 2016 David Cramer |
||
10 | * |
||
11 | * @wordpress-plugin |
||
12 | * Plugin Name: UIX |
||
13 | * Plugin URI: http://cramer.co.za |
||
14 | * Description: UI Framework for WordPress Plugins. |
||
15 | * Version: 1.0.0 |
||
16 | * Author: David Cramer |
||
17 | * Author URI: http://cramer.co.za |
||
18 | * Text Domain: uix |
||
19 | * License: GPL-2.0+ |
||
20 | * License URI: http://www.gnu.org/licenses/gpl-2.0.txt |
||
21 | * Domain Path: /languages |
||
22 | */ |
||
23 | // If this file is called directly, abort. |
||
24 | View Code Duplication | if ( defined( 'WPINC' ) ) { |
|
0 ignored issues
–
show
|
|||
25 | |||
26 | define( 'UIX_CORE', __FILE__ ); |
||
27 | define( 'UIX_PATH', plugin_dir_path( __FILE__ ) ); |
||
28 | define( 'UIX_URL', plugin_dir_url( __FILE__ ) ); |
||
29 | define( 'UIX_VER', '1.0.0' ); |
||
30 | |||
31 | // include uix bootstrap. |
||
32 | require_once UIX_PATH . 'uix-bootstrap.php'; |
||
33 | |||
34 | } |
||
35 |
Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.
You can also find more detailed suggestions in the “Code” section of your repository.