<commit_before>/**
 * Created by at15 on 2016/4/7.
 */

import {Component} from 'angular2/core';
import {Router} from 'angular2/router';
import {UserLoginFormComponent} from './user.login-form.component';

@Component({
    // TODO: is it possible to put this component inside a modal
    selector: 'bform-user-login',
    styleUrls: ['./assets/user/user.login.css'],
    template: '<bform-user-login-form></bform-user-login-form>',
    directives: [UserLoginFormComponent]
})
export class UserLoginComponent {
    constructor(private _router:Router) {

    }

    goToDashBoard() {
        this._router.navigate(['UserDashboard']);
    }

}<commit_msg>[ex] Attempt to use a dehydrated detector<commit_after>/**
 * Created by at15 on 2016/4/7.
 */

import {Component} from 'angular2/core';
import {Router} from 'angular2/router';
import {UserLoginFormComponent} from './user.login-form.component';

@Component({
    // TODO: is it possible to put this component inside a modal
    selector: 'bform-user-login',
    styleUrls: ['./assets/user/user.login.css'],
    template: '<bform-user-login-form (loginSucceeded)="onLoginSucceeded($event)"></bform-user-login-form>',
    directives: [UserLoginFormComponent]
})
export class UserLoginComponent {
    constructor(private _router:Router) {

    }

    onLoginSucceeded(succeeded:boolean) {
        console.log('login succeeded');
        this.goToDashBoard();
    }

    goToDashBoard() {
        this._router.navigate(['UserDashboard']);
    }

}
{'fraction_non_alphanumeric': 0.14782608695652175, 'fraction_numerical': 0.013377926421404682, 'mean_word_length': 3.779552715654952, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, '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': '4537371', 'n_tokens_mistral': 488, 'n_tokens_neox': 468, 'n_words': 101}