<commit_before>import {NgModule} from '@angular/core';
import {RouterModule, Routes} from '@angular/router';
import {SignupComponent} from './signup/signup.component';
import {LoginComponent} from './login/login.component';
import {DBLoggedIn, DBReady} from './db';
import {MeComponent} from './me/me.component';
import {ConfigComponent} from './config/config.component';
import {SwipeComponent} from './swipe/swipe.component';

const routes: Routes = [
  { path: '', redirectTo: '/swipe', pathMatch: 'full', resolve: { db: DBReady }}, // redirect to signup page
  { path: 'swipe', component: SwipeComponent, canActivate: [DBLoggedIn] }, // will prevent none logged in users from accessing it
  { path: 'signup', component: SignupComponent, resolve: { db: DBReady } }, // will activate the route after the db is ready
  { path: 'login', component: LoginComponent, resolve: { db: DBReady } }, // will activate the route after the db is ready
  { path: 'config', component: ConfigComponent,canActivate: [DBLoggedIn] }, // will prevent none logged in users from accessing it
  { path: 'signup/me', component: MeComponent, canActivate: [DBLoggedIn] }, // will prevent none logged in users from accessing it
];

@NgModule({
  imports: [RouterModule.forRoot(routes)],
    exports: [RouterModule],
})
export class AppRoutingModule { }<commit_msg>added space<commit_after>import {NgModule} from '@angular/core';
import {RouterModule, Routes} from '@angular/router';
import {SignupComponent} from './signup/signup.component';
import {LoginComponent} from './login/login.component';
import {DBLoggedIn, DBReady} from './db';
import {MeComponent} from './me/me.component';
import {ConfigComponent} from './config/config.component';
import {SwipeComponent} from './swipe/swipe.component';

const routes: Routes = [
  { path: '', redirectTo: '/swipe', pathMatch: 'full', resolve: { db: DBReady }}, // redirect to signup page
  { path: 'swipe', component: SwipeComponent, canActivate: [DBLoggedIn] }, // will prevent none logged in users from accessing it
  { path: 'signup', component: SignupComponent, resolve: { db: DBReady } }, // will activate the route after the db is ready
  { path: 'login', component: LoginComponent, resolve: { db: DBReady } }, // will activate the route after the db is ready
    {path: 'config', component: ConfigComponent, canActivate: [DBLoggedIn]}, // will prevent none logged in users from accessing it
  { path: 'signup/me', component: MeComponent, canActivate: [DBLoggedIn] }, // will prevent none logged in users from accessing it
];

@NgModule({
  imports: [RouterModule.forRoot(routes)],
    exports: [RouterModule],
})
export class AppRoutingModule { }
{'fraction_non_alphanumeric': 0.14120283899887934, 'fraction_numerical': 0.0, 'mean_word_length': 5.0179775280898875, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '1052095', 'n_tokens_mistral': 774, 'n_tokens_neox': 779, 'n_words': 268}