Code Duplication    Length = 11-15 lines in 2 locations

htdocs/lib2/logic/user.class.php 2 locations

@@ 1020-1030 (lines=11) @@
1017
        return !$error;
1018
    }
1019
1020
    public function canDisableDueLicense()
1021
    {
1022
        global $login;
1023
        $login->verify();
1024
1025
        if ($login->userid != $this->nUserId && ($login->admin & ADMIN_USER) != ADMIN_USER) {
1026
            return false;
1027
        }
1028
1029
        return true;
1030
    }
1031
1032
    /**
1033
     * disables user (if not disabled), removes all licensed content from db and
@@ 920-934 (lines=15) @@
917
        return false;
918
    }
919
920
    public function canDisable()
921
    {
922
        global $login;
923
        $login->verify();
924
925
        if ($login->userid != $this->nUserId && ($login->admin & ADMIN_USER) != ADMIN_USER) {
926
            return false;
927
        }
928
929
        if ($this->getIsActive() != 0) {
930
            return true;
931
        }
932
933
        return false;
934
    }
935
936
    public function disable()
937
    {