<commit_before>import { Component, OnInit } from '@angular/core';
import { Track } from '../_models';
import { TrackService } from '../_services';
import { MdDialog, MdDialogRef } from '@angular/material';
import '../../../node_modules/@swimlane/ngx-datatable/release/index.css';
import '../../../node_modules/@swimlane/ngx-datatable/release/themes/material.css';
import '../../../node_modules/@swimlane/ngx-datatable/release/assets/icons.css';

@Component({
  selector: 'dialog-overview-example-dialog',
  templateUrl: 'updateTrackDialog.component.html',
  styleUrls: ['./tracks.component.css']
})

export class UpdateTrackDialogComponent {
  currentTrack: any;
  trackService: TrackService;
  constructor(public dialogRef: MdDialogRef<UpdateTrackDialogComponent>) {}

  private formatCurrentTrack() : Track {
    if (this.currentTrack.genres.indexOf(',') > -1)
      return {...this.currentTrack, artists: this.currentTrack.artists.split(',')};
    return this.currentTrack;
  }
<commit_msg>cosas<commit_after>import { Component, OnInit } from '@angular/core';
import { Track } from '../_models';
import { TrackService } from '../_services';
import { MdDialog, MdDialogRef } from '@angular/material';
import '../../../node_modules/@swimlane/ngx-datatable/release/index.css';
import '../../../node_modules/@swimlane/ngx-datatable/release/themes/material.css';
import '../../../node_modules/@swimlane/ngx-datatable/release/assets/icons.css';

@Component({
  selector: 'dialog-overview-example-dialog',
  templateUrl: 'updateTrackDialog.component.html',
  styleUrls: ['./tracks.component.css']
})

export class UpdateTrackDialogComponent {
  currentTrack: any;
  trackService: TrackService;
  constructor(public dialogRef: MdDialogRef<UpdateTrackDialogComponent>) {}

  private formatCurrentTrack() : Track {
    console.log(this.currentTrack);
    if (this.currentTrack.artistsIds.indexOf(',') !== -1)
      return {...this.currentTrack, artists: this.currentTrack.artistsIds.split(',') };
    // return {...this.currentTrack, artists: [this.currentTrack.artistsIds]};
  }

{'fraction_non_alphanumeric': 0.17269657501205982, 'fraction_numerical': 0.000964785335262904, 'mean_word_length': 4.560321715817694, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 6, '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': '6627116', 'n_tokens_mistral': 633, 'n_tokens_neox': 620, 'n_words': 109}