mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
BUGFIX Added E_USER_ERROR error to ComponentSet::getExtraData() if a non-numeric child ID is passed
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@71639 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
parent
df36ae07e8
commit
1cb6b5c8ee
@ -73,6 +73,10 @@ class ComponentSet extends DataObjectSet {
|
||||
$parentField = $this->ownerClass . 'ID';
|
||||
$childField = ($this->childClass == $this->ownerClass) ? 'ChildID' : ($this->childClass . 'ID');
|
||||
$result = array();
|
||||
|
||||
if(!is_numeric($childID)) {
|
||||
user_error('ComponentSet::getExtraData() passed a non-numeric child ID', E_USER_ERROR);
|
||||
}
|
||||
|
||||
if(!$componentName) return false;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user