GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

Code Duplication    Length = 31-31 lines in 2 locations

src/php/DataSift/Storyplayer/ProvisioningLib/Provisioners/AnsibleProvisioner.php 1 location

@@ 71-101 (lines=31) @@
68
        $this->st = $st;
69
    }
70
71
    public function buildDefinitionFor($env)
72
    {
73
        // our return value
74
        $provDef = new ProvisioningDefinition;
75
76
        // what are we doing?
77
        $log = Log::usingLog()->startAction("build Ansible provisioning definition");
78
79
        // add in each machine in the environment
80
        foreach ($env->details->machines as $hostId => $machine) {
81
            usingProvisioningDefinition($provDef)->addHost($hostId);
82
83
            foreach ($machine->roles as $role) {
84
                usingProvisioningDefinition($provDef)->addRole($role)->toHost($hostId);
85
            }
86
87
            if (isset($machine->params)) {
88
                $params = [];
89
                foreach ($machine->params as $paramName => $paramValue) {
90
                    $params[$paramName] = fromConfig()->get('hosts.' . $hostId . '.params.'.$paramName);
91
                }
92
                if (count($params)) {
93
                    usingProvisioningDefinition($provDef)->addParams($params)->toHost($hostId);
94
                }
95
            }
96
        }
97
98
        // all done
99
        $log->endAction($provDef);
100
        return $provDef;
101
    }
102
103
    public function provisionHosts(ProvisioningDefinition $hosts, $provConf)
104
    {

src/php/DataSift/Storyplayer/ProvisioningLib/Provisioners/DsbuildProvisioner.php 1 location

@@ 75-105 (lines=31) @@
72
        $this->st = $st;
73
    }
74
75
    public function buildDefinitionFor($env)
76
    {
77
        // our return value
78
        $provDef = new ProvisioningDefinition;
79
80
        // what are we doing?
81
        $log = Log::usingLog()->startAction("build dsbuild provisioning definition");
82
83
        // add in each machine in the environment
84
        foreach ($env->details->machines as $hostId => $machine) {
85
            usingProvisioningDefinition($provDef)->addHost($hostId);
86
87
            foreach ($machine->roles as $role) {
88
                usingProvisioningDefinition($provDef)->addRole($role)->toHost($hostId);
89
            }
90
91
            if (isset($machine->params)) {
92
                $params = [];
93
                foreach ($machine->params as $paramName => $paramValue) {
94
                    $params[$paramName]  = fromConfig()->get('hosts.' . $hostId . '.params.'.$paramName);
95
                }
96
                if (count($params)) {
97
                    usingProvisioningDefinition($provDef)->addParams($params)->toHost($hostId);
98
                }
99
            }
100
        }
101
102
        // all done
103
        $log->endAction($provDef);
104
        return $provDef;
105
    }
106
107
    public function provisionHosts(ProvisioningDefinition $hosts, $provConfig)
108
    {