BUGFIX: Check for empty (from r96441)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/cms/trunk@102469 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
Ingo Schommer 2010-04-12 08:49:40 +00:00
parent 0624cc69ed
commit e5e3804ce9

View File

@ -64,6 +64,9 @@ WidgetAreaEditorClass.prototype = {
this.name = this.getAttribute('name'); this.name = this.getAttribute('name');
var monkeyWith = function(widgets, name) { var monkeyWith = function(widgets, name) {
if (!widgets) {
return;
}
for(var i = 0; i < widgets.length; i++) { for(var i = 0; i < widgets.length; i++) {
widget = widgets[i]; widget = widgets[i];
if (!widget.getAttribute('rewritten') && (widget.id || widget.name)) { if (!widget.getAttribute('rewritten') && (widget.id || widget.name)) {