From 2a59661eb2f1872fa201b7ad3ea5ac920674108f Mon Sep 17 00:00:00 2001 From: xieqiyu Date: Fri, 24 May 2024 10:54:04 +0800 Subject: [PATCH] * Fix bug#50029. --- module/story/control.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/module/story/control.php b/module/story/control.php index ba68c84bc6..e2dd3b4a69 100755 --- a/module/story/control.php +++ b/module/story/control.php @@ -1328,7 +1328,7 @@ class story extends control $this->story->linkStories($storyID, $this->post->stories); if(dao::isError()) return $this->send(array('result' => 'fail', 'message' => dao::getError())); - return $this->send(array('result' => 'success', 'callback' => "const modal = zui.Modal.query('.modal-dialog[data-auto-load=\"story:$storyID\"]'); if(modal) modal.render(); else loadCurrentPage();", 'closeModal' => true)); + return $this->send(array('result' => 'success', 'callback' => "const modal = zui.Modal.query('.modal-dialog[data-auto-load=\"story:$storyID\"]'); if(typeof(modal) !== 'undefined') modal.render(); else loadCurrentPage();", 'closeModal' => true)); } /* Get story, product, products, and queryID. */