<commit_before>
import { AuthService } from 'ng2-ui-auth';
import { Component, OnInit, OnChanges } from '@angular/core';
import { Router } from '@angular/router';

import { LogoutService } from './../shared/logout.service';
import { Logout } from '../loginComponents/logout';
import { TrackLoginService } from './../shared/track-login.service';
import { UserService } from './../loginComponents/user.service';

@Component({
  selector: 'app-navbar',
  templateUrl: './navbar.component.html',
  styleUrls: ['./navbar.component.css'],
  providers: [UserService]
})
export class NavbarComponent extends Logout {
  private user;
  constructor (trackLoginService: TrackLoginService, logoutService: LogoutService, router: Router, userService: UserService) {
    super(trackLoginService, logoutService, router);
    userService.getUser().subscribe(user => {
      this.user = user;
    });
  }
}<commit_msg>Fix for username not always showing up<commit_after>
import { AuthService } from 'ng2-ui-auth';
import { Component, OnInit, OnChanges } from '@angular/core';
import { Router } from '@angular/router';

import { LogoutService } from './../shared/logout.service';
import { Logout } from '../loginComponents/logout';
import { TrackLoginService } from './../shared/track-login.service';
import { UserService } from './../loginComponents/user.service';

@Component({
  selector: 'app-navbar',
  templateUrl: './navbar.component.html',
  styleUrls: ['./navbar.component.css'],
})
export class NavbarComponent extends Logout {
  private user;
  constructor (trackLoginService: TrackLoginService, logoutService: LogoutService, router: Router, userService: UserService) {
    super(trackLoginService, logoutService, router);
    userService.user$.subscribe(user => {
      this.user = user;
    });
  }
}
{'fraction_non_alphanumeric': 0.14938684503901895, 'fraction_numerical': 0.0011148272017837235, 'mean_word_length': 4.557275541795666, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, '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': '6520935', 'n_tokens_mistral': 520, 'n_tokens_neox': 515, 'n_words': 128}