if (routerHistory
          && (routerHistory.location.pathname === '/publish' || routerHistory.location.pathname === '/statuses/new')
          && window.history.state