From 6238ed6b779535bf7a44153fd1c4999d53f06c65 Mon Sep 17 00:00:00 2001 From: Sean Robertson Date: Wed, 28 Jul 2021 16:04:28 +1200 Subject: [PATCH] Further simplification of code. --- client/homebrew/pages/sharePage/sharePage.jsx | 24 ++++++------------- 1 file changed, 7 insertions(+), 17 deletions(-) diff --git a/client/homebrew/pages/sharePage/sharePage.jsx b/client/homebrew/pages/sharePage/sharePage.jsx index f8e19a8d1..6c0771a74 100644 --- a/client/homebrew/pages/sharePage/sharePage.jsx +++ b/client/homebrew/pages/sharePage/sharePage.jsx @@ -79,21 +79,6 @@ const SharePage = createClass({ ; }, - renderPrint : function(){ - if(!this.props.brew.shareId) return; - return ; - }, - - renderSourceDropdown : function(){ - if(!this.props.brew.shareId) return; - return this.handleDropdown(true)} - onMouseLeave={()=>this.handleDropdown(false)}> - source - {this.renderDropdown()} - ; - }, - render : function(){ return
@@ -103,8 +88,13 @@ const SharePage = createClass({ - {this.renderPrint()} - {this.renderSourceDropdown()} + {this.props.shareId && + this.handleDropdown(true)} + onMouseLeave={()=>this.handleDropdown(false)}> + source + {this.renderDropdown()} + }