You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The result of a character request by ID always shows classes, etc. as null. I found the issue and made a fix, but I rather not make a pull request as this is a very dirty fix. I will still explain what I did and what caused the issue in case you want to fix it.
This is the result currently:
Explaining the problem
In the page-parser.ts only the DOM from the character profile will be requested, so /lodestone/character/:id. But not from the Class/Job overview, so /lodestone/character/:id/class_job. That is the one we need in order to apply the css query selectors for the classes.
My (dirty) fix for that
What i just did now is, I added another DOM request at the start of the parse() function that is very similar to the existing one, but for the /class_job path:
Now we have document for all the general info and classJobDocument for the classes.
Then later, when we call this.handleColumn() in currently line 54, we have to pass in the classJobDocument instead of document if the column is one of the classes.
For that (and this is the very dirty part), I just made a simple array with all classes and checked the column:
Now we just have to pass correctDocument to this.handleColumn() instead of document and it will work again.
And this is the result with the same character after the fix:
(Eureka is in fact null, because I never played that, but I saw the Eureka info on a friends char!)
The text was updated successfully, but these errors were encountered:
I don't think this is a duplicate of the other issue. Parsing with Nodestone returns null for all classes. The other issue was only related to Eureka/Bozja.
Situation
The result of a character request by ID always shows classes, etc. as null. I found the issue and made a fix, but I rather not make a pull request as this is a very dirty fix. I will still explain what I did and what caused the issue in case you want to fix it.
This is the result currently:
Explaining the problem
In the page-parser.ts only the DOM from the character profile will be requested, so
/lodestone/character/:id
. But not from the Class/Job overview, so/lodestone/character/:id/class_job
. That is the one we need in order to apply the css query selectors for the classes.My (dirty) fix for that
What i just did now is, I added another DOM request at the start of the
parse()
function that is very similar to the existing one, but for the/class_job
path:Now we have
document
for all the general info andclassJobDocument
for the classes.Then later, when we call
this.handleColumn()
in currently line 54, we have to pass in theclassJobDocument
instead ofdocument
if the column is one of the classes.For that (and this is the very dirty part), I just made a simple array with all classes and checked the column:
Now we just have to pass
correctDocument
tothis.handleColumn()
instead ofdocument
and it will work again.And this is the result with the same character after the fix:
(Eureka is in fact null, because I never played that, but I saw the Eureka info on a friends char!)
The text was updated successfully, but these errors were encountered: