NPM: TypeError: Cannot read property 'access' of undefined

Hello,

I’m installing a package from GitHub using npm. I’m doing this because I need to change a package called ‘klasa’ to fit my needs.
This is in my package.json:
"klasa": "github:username/reponame#master"
I’m getting this fatal error:
TypeError: Cannot read property 'access' of undefined.

Help is appreciated!


MOD EDIT: formatting

Hi @chrissie1234 is that the precise content that’s in your package.json? That doesn’t refer to a real GitHub repo, so it won’t work as is. Perhaps if you share your project name someone can give specific guidance.

Alright, this is the whole package.json:

{
  "//1": "describes your app and its dependencies",
  "//2": "https://docs.npmjs.com/files/package.json",
  "//3": "updating this file will download and update your packages",
  "name": "hello-express",
  "version": "0.0.1",
  "description": "A simple Node app built on Express, instantly up and running.",
  "main": "server.js",
  "scripts": {
    "start": "node server.js"
  },
  "dependencies": {
    "express": "^4.16.4",
    "klasa": "github:chrissie1234/klasa#master",
    "discord.js": "^11.5.0"
  },
  "engines": {
    "node": "8.x"
  },
  "repository": {
    "url": "https://glitch.com/edit/#!/hello-express"
  },
  "license": "MIT",
  "keywords": [
    "node",
    "glitch",
    "express"
  ]
}

Thanks for the extra info, @chrissie1234! I’m able to install everything as expected from that package.json, so the undefined error message is coming from somewhere else in your code, which seemed likely. We’ll probably need to see the relevant code to be able to be of further help.

This solved the issue for me:
"klasa": "git+https://github.com/chrissie1234/klasa.git".
I’m reviewing my code now. Thank you for your service.