diff --git a/pages/template/list-news/detail/detail.uvue b/pages/template/list-news/detail/detail.uvue index 09f151e7de0eecaddd97f0dee6ef8e9d36e3dcac..0d1ef04a3fb5fe053a517fd321241bfc843e6b3b 100644 --- a/pages/template/list-news/detail/detail.uvue +++ b/pages/template/list-news/detail/detail.uvue @@ -23,10 +23,11 @@ } }, onLoad(event) { - // console.log(event); - this.post_id = event["post_id"] ?? ""; - this.cover = event["cover"] ?? ""; - this.title = event["title"] ?? ""; + if (event != null) { + this.post_id = event["post_id"] ?? ""; + this.cover = event["cover"] ?? ""; + this.title = event["title"] ?? ""; + } this.getDetail(); }, methods: {