Skip to content

Commit

Permalink
Merge pull request #59 from ruebot/7.x-ISLANDORA-1042
Browse files Browse the repository at this point in the history
ISLANDORA-1042 -- DESTROY ALL DEPRECATED CODE!
  • Loading branch information
jordandukart committed Sep 25, 2014
2 parents 6ec3cc1 + 08d195c commit d742d2a
Showing 1 changed file with 0 additions and 40 deletions.
40 changes: 0 additions & 40 deletions includes/bookmark.inc
Original file line number Diff line number Diff line change
Expand Up @@ -124,46 +124,6 @@ abstract class Bookmark implements BookmarkInterface {
$this->isDeletable = TRUE;
}

/**
* Somewhat more graceful deprecation of old properties.
*/
public function __get($property) {
if ($property == 'userList') {
module_load_include('inc', 'islandora', 'includes/utilities');
$message = islandora_deprecated('7.x-1.3', 'Use the methods {get,add,remove}Users(), instead of accessing as a property.');
trigger_error(filter_xss($message), E_USER_DEPRECATED);
return $this->getUsers();
}
elseif ($property == 'pidList') {
module_load_include('inc', 'islandora', 'includes/utilities');
$message = islandora_deprecated('7.x-1.3', 'Use the methods {get,add,remove}Pids(), instead of accessing as a property.');
trigger_error(filter_xss($message), E_USER_DEPRECATED);
return $this->getPids();
}
}

/**
* Somewhat more graceful deprecation of old properties.
*/
public function __set($property, $value) {
if ($property == 'userList') {
module_load_include('inc', 'islandora', 'includes/utilities');
$message = islandora_deprecated('7.x-1.3', 'Use the methods {get,add,remove}Users(), instead of accessing as a property.');
trigger_error(filter_xss($message), E_USER_DEPRECATED);
$this->removeUsers($this->getUsers());
$this->addUsers($value);
return $value;
}
elseif ($property == 'pidList') {
module_load_include('inc', 'islandora', 'includes/utilities');
$message = islandora_deprecated('7.x-1.3', 'Use the methods {get,add,remove}Pids(), instead of accessing as a property.');
trigger_error(filter_xss($message), E_USER_DEPRECATED);
$this->removeAllPids();
$this->addPids($value);
return $value;
}
}

/**
* Accessor for the list ID.
*
Expand Down

0 comments on commit d742d2a

Please sign in to comment.