<commit_before>import { inject } from 'aurelia-framework';
import { Router } from 'aurelia-router';
import { HackerNewsApi } from '../../services/api';

@inject(Router, HackerNewsApi)
export class User {
    user: any;

    private readonly router: Router;
    private readonly api: HackerNewsApi;
    private id: string;

    constructor(router: Router, api: HackerNewsApi) {
        this.router = router;
        this.api = api;
    }

    async activate(params: any): Promise<void> {
        if (params.id === undefined) {
            this.router.navigateToRoute('news');
            return;
        }

        this.id = params.id;
        this.user = await this.api.fetch('user/' + this.id);<commit_msg>Use template string in User view-model<commit_after>import { inject } from 'aurelia-framework';
import { Router } from 'aurelia-router';
import { HackerNewsApi } from '../../services/api';

@inject(Router, HackerNewsApi)
export class User {
    user: any;

    private readonly router: Router;
    private readonly api: HackerNewsApi;
    private id: string;

    constructor(router: Router, api: HackerNewsApi) {
        this.router = router;
        this.api = api;
    }

    async activate(params: any): Promise<void> {
        if (params.id === undefined) {
            this.router.navigateToRoute('news');
            return;
        }

        this.id = params.id;
        this.user = await this.api.fetch(`user/${this.id}`);
{'fraction_non_alphanumeric': 0.1299513551077137, 'fraction_numerical': 0.0, 'mean_word_length': 2.6272040302267, 'pattern_counts': {'":': 0, '<': 5, '<?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': '5489569', 'n_tokens_mistral': 434, 'n_tokens_neox': 429, 'n_words': 109}