Passed
Push — master ( 077fbd...836ec9 )
by Michael
04:09
created

Extcal_2_34::alterTable_etablissement()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 11
Code Lines 6

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
eloc 6
dl 0
loc 11
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 0
1
<?php
2
/**
3
 * extcal module.
4
 *
5
 * You may not change or alter any portion of this comment or credits
6
 * of supporting developers from this source code or any supporting source code
7
 * which is considered copyrighted (c) material of the original comment or credit authors.
8
 * This program is distributed in the hope that it will be useful,
9
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
11
 *
12
 * @copyright           XOOPS Project (https://xoops.org)
13
 * @license             http://www.fsf.org/copyleft/gpl.html GNU public license
14
 *
15
 * @since               2.2
16
 *
17
 * @author              JJDai <http://xoops.kiolo.com>
18
 **/
19
20
//----------------------------------------------------
21
class Extcal_2_34
22
{
23
    //----------------------------------------------------
24
25
    /**
26
     * @param \XoopsModule $module
27
     * @param             $options
28
     */
29
    public function __construct(\XoopsModule $module, $options)
0 ignored issues
show
Unused Code introduced by
The parameter $module is not used and could be removed. ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-unused  annotation

29
    public function __construct(/** @scrutinizer ignore-unused */ \XoopsModule $module, $options)

This check looks for parameters that have been defined for a function or method, but which are not used in the method body.

Loading history...
Unused Code introduced by
The parameter $options is not used and could be removed. ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-unused  annotation

29
    public function __construct(\XoopsModule $module, /** @scrutinizer ignore-unused */ $options)

This check looks for parameters that have been defined for a function or method, but which are not used in the method body.

Loading history...
30
    {
31
        global $xoopsDB;
32
33
        $this->alterTable_etablissement();
34
    }
35
36
    //----------------------------------------------------
37
    public function alterTable_etablissement()
38
    {
39
        global $xoopsDB;
40
        $tbl = $xoopsDB->prefix('extcal_etablissement');
41
42
        $sql = <<<__sql__
43
ALTER TABLE `{$tbl}`
44
 CHANGE `desc` `description` TEXT CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL;
45
__sql__;
46
47
        $xoopsDB->queryF($sql);
48
        //echo "<hr>{$sql}<hr>";
49
    }
50
51
    //----------------------------------------------------
52
53
    //-----------------------------------------------------------------
54
}   // fin de la classe
55