mirror of
https://github.com/silverstripe/silverstripe-subsites
synced 2024-10-22 09:05:55 +00:00
Merge pull request #329 from mikenz/patch-1
Bugfix: Don't assume all forms have a URLSegment field
This commit is contained in:
commit
1cdae5024a
@ -154,7 +154,9 @@ class SiteTreeSubsites extends DataExtension
|
||||
}
|
||||
|
||||
$urlsegment = $fields->dataFieldByName('URLSegment');
|
||||
$urlsegment->setURLPrefix($baseLink);
|
||||
if ($urlsegment) {
|
||||
$urlsegment->setURLPrefix($baseLink);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user