Fixing bug #4088

http://tracker.modx.com/issues/4088