Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

205
Views
Polymorphic callback function not recognized

I am getting the error Uncaught (in promise) TypeError: modNums is not a function. I am following a guide and what I have below is roughly similar to what they did.

Is the issue coming from the fact that I am trying to call the callback inside of a fetch callback? How can I make the modNums function get called? Mind you modNums is just the name of the parameter and there are multiple function that are meant to be accepted for that function value (hence polymorphism).

function updatePageText (chapter, page, modNums) {
  fetch("../../assets/json_files/parsedPages.json")
    .then((Response) => Response.json())
    .then((data) => {
      modNums(chapter, page, data); 

_

updatePageText(chapterNum, pageNum, increasePage);
about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!