<commit_before>import React from 'react';
import { BrowserRouter as Router, Route, Switch } from 'react-router-dom';

// =========== Components ===========
import App from '../components/app';
import NotFound from '../components/public-pages/not-found';
// Layout
import Header from '../components/navigation/header';
import Footer from '../components/navigation/footer';
// authentication
import Register from '../components/auth/register';
import SignIn from '../components/auth/sign-in';
import Profile from '../components/auth/profile';


export default (
  <Router>
    <div>
      <Header />
      <Switch>
        <Route exact path="/" component={App} />
        <Route path="/register" component={Register} />
        <Route path="/sign_in" component={SignIn} />
        <Route path="/profile" component={Profile} />
        <Route component={NotFound} />
      </Switch>
      <footer />
    </div>
  </Router>
)<commit_msg>Hide components if user is logged<commit_after>import React from 'react';
import { BrowserRouter as Router, Route, Switch } from 'react-router-dom';

// =========== Components ===========
import App from '../components/app';
import NotFound from '../components/public-pages/not-found';
// Products
import Products from '../components/products/';
// Layout
import Header from '../components/navigation/header';
import Footer from '../components/navigation/footer';
// authentication
import Register from '../components/auth/register';
import SignIn from '../components/auth/sign-in';
import Profile from '../components/auth/profile';
// Hide order component
import RequireAuth from '../components/auth/hoc/require-auth';
import HideAuth from '../components/auth/hoc/hide-auth';


export default (
  <Router>
    <div>
      <Header />
      <Switch>
        <Route exact path="/" component={App} />
        <Route path="/register" component={HideAuth(Register)} />
        <Route path="/sign_in" component={HideAuth(SignIn)} />
        <Route path="/profile" component={RequireAuth(Profile)} />
        <Route path="/products" component={HideAuth(Products)} />
        <Route component={NotFound} />
      </Switch>
      <footer />
    </div>
  </Router>
)
{'fraction_non_alphanumeric': 0.17816354499771586, 'fraction_numerical': 0.0, 'mean_word_length': 3.353876739562624, 'pattern_counts': {'":': 0, '<': 30, '<?xml version=': 0, '>': 30, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2471495', 'n_tokens_mistral': 585, 'n_tokens_neox': 569, 'n_words': 160}