From 833562f9ba8dade24ff25357b53a22186581cf76 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=98=8E?= <775174143@qq.com> Date: Mon, 16 Mar 2020 21:51:50 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- public/react/src/modules/courses/Video/VideoIndex.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/public/react/src/modules/courses/Video/VideoIndex.js b/public/react/src/modules/courses/Video/VideoIndex.js index fe52b17dc..f52f54859 100644 --- a/public/react/src/modules/courses/Video/VideoIndex.js +++ b/public/react/src/modules/courses/Video/VideoIndex.js @@ -243,10 +243,9 @@ class VideoIndex extends Component{ } render(){ const { videos , upload , videoData , type , liveData , lives , page , liveVisible , isSpining , liveId , otherLinkVisible,statistics } = this.state; - const { is_teacher } = this.props.user; const { coursesId , videoId }=this.props.match.params; - - const {course_identity} = this.props.coursedata; + let course_identity = this.props&&this.props.coursedata; + let is_teacher = this.props&&this.props.user; const flag = parseInt(course_identity) < 5; const newOperation = flag; const new_upload = flag && (is_teacher && this.props.checkIfProfessionalCertification());