Skip to content

Commit

Permalink
SharingButtonsPreviewButton: add forwardRef flag to connect to make t…
Browse files Browse the repository at this point in the history
…he button reffable (#37570)
  • Loading branch information
jsnajdr authored Nov 13, 2019
1 parent 1835f94 commit 35fdd8d
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions client/my-sites/marketing/buttons/preview-button.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -99,8 +99,11 @@ class SharingButtonsPreviewButton extends React.Component {
/* eslint-enable wpcalypso/jsx-classname-namespace */
}

export default connect( state => {
return {
export default connect(
state => ( {
path: getCurrentRouteParameterized( state, getSelectedSiteId( state ) ),
};
} )( SharingButtonsPreviewButton );
} ),
null,
null,
{ forwardRef: true }
)( SharingButtonsPreviewButton );

0 comments on commit 35fdd8d

Please sign in to comment.