# TypeError: wrapWithResCheck is not a function - error

**URL:** <https://community.stardog.com/t/typeerror-wrapwithrescheck-is-not-a-function-error/1592>\
**Category:** Support\
**Created:** [April 11, 2019, 4:18pm UTC](https://community.stardog.com/t/typeerror-wrapwithrescheck-is-not-a-function-error/1592 "2019-04-11T16:18:31Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![R3000](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.stardog.com/r3000/32/358_2.png) [@R3000](https://community.stardog.com/u/R3000)\
**Post date:** [April 11, 2019, 4:18pm UTC](https://community.stardog.com/t/typeerror-wrapwithrescheck-is-not-a-function-error/1592/1 "2019-04-11T16:18:32Z")

</div>

While running this command:

`C:\Projects>node stardog-react\src\data\load-data.js`

I am getting the following error - any idea why?

```
Creating StarWarsDB...

C:\Projects\stardog-react\src\data\load-data.js:19
    .then(wrapWithResCheck(() => query.execute(conn, dbName, insertQuery)))
          ^

TypeError: wrapWithResCheck is not a function
    at loadData (C:\Projects\stardog-react\src\data\load-data.js:19:11)
    at Object.<anonymous> (C:\Projects\stardog-react\src\data\load-data.js:24:1)
    at Module._compile (module.js:652:30)
    at Object.Module._extensions..js (module.js:663:10)
    at Module.load (module.js:565:32)
    at tryModuleLoad (module.js:505:12)
    at Function.Module._load (module.js:497:3)
    at Function.Module.runMain (module.js:693:10)
    at startup (bootstrap_node.js:191:16)
    at bootstrap_node.js:612:3
```

---

<div class="post-metadata">

**Author:** ![R3000](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.stardog.com/r3000/32/358_2.png) [@R3000](https://community.stardog.com/u/R3000)\
**Post date:** [April 11, 2019, 4:20pm UTC](https://community.stardog.com/t/typeerror-wrapwithrescheck-is-not-a-function-error/1592/2 "2019-04-11T16:20:58Z")

</div>

The command comes from [https://www.stardog.com/tutorials/stardog-react-5-easy-steps/](https://www.stardog.com/tutorials/stardog-react-5-easy-steps/)

---

<div class="post-metadata">

**Author:** ![jason](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.stardog.com/jason/32/226_2.png) [@jason](https://community.stardog.com/u/jason)\
**Post date:** [April 11, 2019, 4:22pm UTC](https://community.stardog.com/t/typeerror-wrapwithrescheck-is-not-a-function-error/1592/3 "2019-04-11T16:22:56Z")

</div>

Hi Radu,

Can you paste the contents of C:\Projects\stardog-react\src\data\load-data.js and C:\Projects\stardog-react\src\helpers\wrapWithResCheck.js here?

Thanks,  
Jason

---

<div class="post-metadata">

**Author:** ![R3000](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.stardog.com/r3000/32/358_2.png) [@R3000](https://community.stardog.com/u/R3000)\
**Post date:** [April 11, 2019, 4:29pm UTC](https://community.stardog.com/t/typeerror-wrapwithrescheck-is-not-a-function-error/1592/4 "2019-04-11T16:29:43Z")

</div>

That is right - it was empty - saved it and onto the next error

Thanks,  
Radu

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex030/uploads/stardog/original/2X/e/ed66b48a616f505106a4acde3c9cee7e6da9bc67.svg) [@system](https://community.stardog.com/u/system)\
**Post date:** [April 25, 2019, 4:29pm UTC](https://community.stardog.com/t/typeerror-wrapwithrescheck-is-not-a-function-error/1592/5 "2019-04-25T16:29:43Z")

</div>

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.
