|
|
@@ -46,12 +46,11 @@ export class FrontcraftCharacterComponent implements OnInit{
|
|
46
|
46
|
this.tokens = tokens
|
|
47
|
47
|
})
|
|
48
|
48
|
|
|
49
|
|
- this.dataLink = 'https://classic.warcraftlogs.com/v1/rankings/character/'+this.char.charactername.replace(/^\w/, c => c.toUpperCase())+'/Gandling/EU?metric=dps&api_key=c698515ab4f592cdb848d80b3abe616c'
|
|
50
|
|
-
|
|
|
49
|
+ this.dataLink = "https://classic.warcraftlogs.com:443/v1/parses/character/"+this.char.charactername.replace(/^\w/, c => c.toUpperCase())+"/Gandling/EU?api_key=c698515ab4f592cdb848d80b3abe616c&metric=dps"
|
|
51
|
50
|
|
|
52
|
51
|
fetch(this.dataLink).then(raw => raw.json().then((json) => {
|
|
53
|
|
- if(json.length-1 < 0) return
|
|
54
|
|
- const data = json[json.length-1]
|
|
|
52
|
+ if(json.length > 0) return
|
|
|
53
|
+ const data = json[0]
|
|
55
|
54
|
|
|
56
|
55
|
this.boss2 = {
|
|
57
|
56
|
name: data.encounterName,
|
|
|
@@ -66,8 +65,8 @@ export class FrontcraftCharacterComponent implements OnInit{
|
|
66
|
65
|
}))
|
|
67
|
66
|
|
|
68
|
67
|
fetch(this.dataLink).then(raw => raw.json().then((json) => {
|
|
69
|
|
- if(json.length-2 < 0) return
|
|
70
|
|
- const data = json[json.length-2]
|
|
|
68
|
+ if(json.length > 1) return
|
|
|
69
|
+ const data = json[1]
|
|
71
|
70
|
|
|
72
|
71
|
this.boss1 = {
|
|
73
|
72
|
name: data.encounterName,
|