DoctorMcKay / node-globaloffensive

A Node.js module to connect to and interact with the CS2 game coordinator. Mostly used to get item data.
https://www.npmjs.com/package/globaloffensive
MIT License
262 stars 61 forks source link

Error: Cannot find module 'protobufjs/minimal' #22

Closed dasyah closed 5 years ago

dasyah commented 5 years ago

its was work fine before I restart code,then I got this error

ps: I only put this on my code : const GlobalOffensive = require('globaloffensive'); nothing else

Error: Cannot find module 'protobufjs/minimal' at Function.Module._resolveFilename (internal/modules/cjs/loader.js:581:15) at Function.Module._load (internal/modules/cjs/loader.js:507:25) at Module.require (internal/modules/cjs/loader.js:637:17) at require (internal/modules/cjs/helpers.js:22:18) at E:\new\commend\node_modules\globaloffensive\protobufs\generated\base_gcmessages.js:8:34 at Object. (E:\new\new\node_modules\globaloffensive\protobufs\generated\base_gcmessages.js:10:3) at Module._compile (internal/modules/cjs/loader.js:689:30) at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10) at Module.load (internal/modules/cjs/loader.js:599:32) at tryModuleLoad (internal/modules/cjs/loader.js:538:12)

k1de commented 5 years ago

@dasyah It happened to me too. Try npm update or uninstall and install package again.

dasyah commented 5 years ago

@dasyah It happened to me too. Try ‘npm update’ or uninstall and install package again.

thanks mate ‘npm update’ solved my problem