From 7ed8c22fd8b6f9b7295dda9eb581367349c7e5f0 Mon Sep 17 00:00:00 2001 From: cdujeu Date: Thu, 7 Apr 2016 14:19:50 +0200 Subject: [PATCH] Use original_path for header if present in metadata. --- core/src/plugins/action.share/res/react/ShareDialog.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/core/src/plugins/action.share/res/react/ShareDialog.js b/core/src/plugins/action.share/res/react/ShareDialog.js index 47300bb246..dc8fd14a1e 100644 --- a/core/src/plugins/action.share/res/react/ShareDialog.js +++ b/core/src/plugins/action.share/res/react/ShareDialog.js @@ -187,11 +187,16 @@ var HeaderPanel = React.createClass({ mixins:[ContextConsumerMixin], render: function(){ + + let nodePath = this.props.shareModel.getNode().getPath(); + if(this.props.shareModel.getNode().getMetadata().get("original_path")){ + nodePath = this.props.shareModel.getNode().getMetadata().get("original_path"); + } return (
{this.context.getMessage('44').replace('%s', PathUtils.getBasename(this.props.shareModel.getNode().getPath()))}
+ >{this.context.getMessage('44').replace('%s', PathUtils.getBasename(nodePath))}
); }