'use strict';

Object.defineProperty(exports, "__esModule", {
  value: true
});

var _reactRedux = require('react-redux');

var _login = require('../actions/login');

var _reducers = require('../reducers');

var _Router = require('../components/Router');

var _Router2 = _interopRequireDefault(_Router);

function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }

var mapStateToProps = function mapStateToProps(state) {
  return {
    username: (0, _reducers.getUserUsername)(state)
  };
};

var mapDispatchToProps = {
  redirectLogin: _login.redirectLogin
};

exports.default = (0, _reactRedux.connect)(mapStateToProps, mapDispatchToProps)(_Router2.default);