mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
Merge pull request #4609 from tractorcow/pulls/3.1/fix-classinfo-breakage
BUG Fix ClassInfo::table_for_object_field
This commit is contained in:
commit
a59a90c6b5
@ -301,7 +301,11 @@ class ClassInfo {
|
||||
* @return string
|
||||
*/
|
||||
public static function table_for_object_field($candidateClass, $fieldName) {
|
||||
if(!$candidateClass || !$fieldName || !is_subclass_of($candidateClass, 'DataObject')) {
|
||||
if(!$candidateClass
|
||||
|| !$fieldName
|
||||
|| !class_exists($candidateClass)
|
||||
|| !is_subclass_of($candidateClass, 'DataObject')
|
||||
) {
|
||||
return null;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user