Code Duplication    Length = 6-6 lines in 2 locations

lib/elFinderVolumeBox.class.php 1 location

@@ 139-144 (lines=6) @@
136
            $this->session->remove('BoxTokens');
137
        }
138
139
        if (isset($options['id'])) {
140
            $this->session->set('nodeId', $options['id']);
141
        } elseif ($_id = $this->session->get('nodeId')) {
142
            $options['id'] = $_id;
143
            $this->session->set('nodeId', $_id);
144
        }
145
146
        try {
147
            if (empty($options['client_id']) || empty($options['client_secret'])) {

lib/elFinderVolumeOneDrive.class.php 1 location

@@ 136-141 (lines=6) @@
133
            $this->session->remove('OneDriveTokens');
134
        }
135
136
        if (isset($options['id'])) {
137
            $this->session->set('nodeId', $options['id']);
138
        } elseif ($_id = $this->session->get('nodeId')) {
139
            $options['id'] = $_id;
140
            $this->session->set('nodeId', $_id);
141
        }
142
143
        try {
144
            if (empty($options['client_id']) || empty($options['client_secret'])) {