Skip to content

Commit

Permalink
ISLANDORA-1042 -- DESTROY ALL DEPRECATED CODE!
Browse files Browse the repository at this point in the history
  • Loading branch information
ruebot committed Sep 5, 2014
1 parent 2582aa7 commit 08d195c
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 08d195c

Please sign in to comment.