public static function fromResourceLink($resourceLink, $ltiUserId)
    {

        $user = new User();
        $user->resourceLink = $resourceLink;
        if (!is_null($resourceLink)) {
            $user->resourceLinkId = $resourceLink->getRecordId();
            $user->dataConnector = $resourceLink->getDataConnector();
        }
        $user->ltiUserId = $ltiUserId;
        if (!empty($ltiUserId)) {
            $user->load();
        }

        return $user;

    }