Skip to content

Commit

Permalink
Fix the bug on where we don't pass domains object when there's no sel…
Browse files Browse the repository at this point in the history
…ected site.
  • Loading branch information
umurkontaci committed Mar 4, 2016
1 parent 55dcd51 commit a10deea
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions client/components/data/domain-management/email/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -31,14 +31,8 @@ var stores = [
];

function getStateFromStores( props ) {
let domains;

if ( props.selectedSite ) {
domains = DomainsStore.getBySite( props.selectedSite.ID );
}

return {
domains,
domains: DomainsStore.getBySite( props.selectedSite.ID ) || {},
cart: CartStore.get(),
context: props.context,
products: props.products,
Expand Down Expand Up @@ -87,6 +81,7 @@ const EmailData = React.createClass( {
render() {
return (
<StoreConnection
domains={ this.props.domains }
googleAppsUsers={ this.props.googleAppsUsers }
googleAppsUsersLoaded={ this.props.googleAppsUsersLoaded }
component={ this.props.component }
Expand Down

0 comments on commit a10deea

Please sign in to comment.