Przeglądaj źródła

delete ennecessary code

yusuketk 7 lat temu
rodzic
commit
16643a1e66

+ 1 - 2
resource/js/components/PageComment/CommentForm.js

@@ -123,7 +123,6 @@ export default class CommentForm extends React.Component {
 
 
 
 
   render() {
   render() {
-    const isMarkdown = this.state.isMarkdown;
     const crowi = this.props.crowi;
     const crowi = this.props.crowi;
     const username = crowi.me;
     const username = crowi.me;
     const user = crowi.findUser(username);
     const user = crowi.findUser(username);
@@ -148,7 +147,7 @@ export default class CommentForm extends React.Component {
                       <textarea className="comment-form-comment form-control" id="comment-form-comment" name="comment" required placeholder="Write comments here..." value={this.state.comment} onChange={this.updateState} >
                       <textarea className="comment-form-comment form-control" id="comment-form-comment" name="comment" required placeholder="Write comments here..." value={this.state.comment} onChange={this.updateState} >
                       </textarea>
                       </textarea>
                     </Tab>
                     </Tab>
-                    { isMarkdown == true &&
+                    { this.state.isMarkdown == true &&
                     <Tab eventKey={2} title="Preview">
                     <Tab eventKey={2} title="Preview">
                       <div className="comment-form-preview">
                       <div className="comment-form-preview">
                        {commentPreview}
                        {commentPreview}