Skip to content
Snippets Groups Projects
Commit b77e7743 authored by Alex Barth's avatar Alex Barth
Browse files

Throw exception if object is disabled.

parent 657c1e09
No related branches found
No related tags found
No related merge requests found
......@@ -77,13 +77,16 @@ abstract class FeedsConfigurable {
}
/**
* Determine whether this object is persistent. I. e. it is defined either
* in code or in the database.
* Determine whether this object is persistent and enabled. I. e. it is
* defined either in code or in the database and it is enabled.
*/
public function existing() {
if ($this->export_type == FEEDS_EXPORT_NONE) {
throw new FeedsNotExistingException(t('Object is not persistent.'));
}
if ($this->disabled) {
throw new FeedsNotExistingException(t('Object is disabled.'));
}
return $this;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment