Code Duplication    Length = 2-2 lines in 2 locations

dashboard/application/models/computing-support/New_account_model.php 1 location

@@ 19-20 (lines=2) @@
16
        // specify the LDAP server to connect to
17
        $conn = ldap_connect($this->config->item('ldapserver')) or die("Oh no can't create LDAP connection");
18
        // bind to the LDAP server specified above
19
        if (!ldap_bind($conn, $this->config->item('ldapbindun'),"@".$this->config->item('ldapdomain'), $this->config->item('ldapbindpass')))
20
            echo "Invalid credentials.";
21
        // Search for user in directory
22
        $cred = explode('\\', $username);
23
        list($domain, $user) = $cred;

dashboard/application/models/computing-support/Temporary_account_model.php 1 location

@@ 20-21 (lines=2) @@
17
        // specify the LDAP server to connect to
18
        $conn = ldap_connect($this->config->item('ldapserver')) or die("Oh no can't create LDAP connection");
19
        // bind to the LDAP server specified above
20
        if (!ldap_bind($conn, $this->config->item('ldapbindun'),"@".$this->config->item('ldapdomain'), $this->config->item('ldapbindpass')))
21
            echo "Invalid credentials.";
22
        // Search for user in directory
23
        $cred = explode('\\', $username);
24
        list($domain, $user) = $cred;