Fix for modal dialog