Completed
Push — master ( c30a0b...37c0e6 )
by Nate
08:20
created

Install::safeUp()   A

Complexity

Conditions 3
Paths 3

Size

Total Lines 12

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 12

Importance

Changes 0
Metric Value
dl 0
loc 12
rs 9.8666
c 0
b 0
f 0
ccs 0
cts 7
cp 0
cc 3
nc 3
nop 0
crap 12
1
<?php
2
3
/**
4
 * @copyright  Copyright (c) Flipbox Digital Limited
5
 * @license    https://flipboxfactory.com/software/hubspot/license
6
 * @link       https://www.flipboxfactory.com/software/hubspot/
7
 */
8
9
namespace flipbox\craft\hubspot\migrations;
10
11
use craft\db\Migration;
12
13
/**
14
 * @author Flipbox Factory <[email protected]>
15
 * @since 1.0.0
16
 */
17
class Install extends Migration
18
{
19
    /**
20
     * @inheritdoc
21
     */
22
    public function safeUp()
23
    {
24
        if (false === (new ObjectAssociations())->safeUp()) {
25
            return false;
26
        };
27
28
        if (false === (new m190222_101208_connections())->safeUp()) {
29
            return false;
30
        };
31
32
        return true;
33
    }
34
35
    /**
36
     * @inheritdoc
37
     */
38
    public function safeDown()
39
    {
40
        if (false === (new ObjectAssociations())->safeDown()) {
41
            return false;
42
        };
43
44
        if (false === (new m190222_101208_connections())->safeDown()) {
45
            return false;
46
        };
47
48
        return true;
49
    }
50
}
51