Skip to content

Blowfish is not a constructor #11

@expertup

Description

@expertup
22: const Blowfish = require('javascript-blowfish');
23: const bf = new Blowfish("xxxxxxxxxxxx");

TypeError: Blowfish is not a constructor
at Object. (C:\Users\Piotr\Documents\Application\app.js:23:12)
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)
at Function.Module._load (internal/modules/cjs/loader.js:530:3)
at Function.Module.runMain (internal/modules/cjs/loader.js:742:12)
at startup (internal/bootstrap/node.js:283:19)
at bootstrapNodeJSCore (internal/bootstrap/node.js:743:3)

I'm runnig node on widnows 10, Node version v10.15.0, NPM version 6.7.0.

I want send encrypted key from server to browser and decode them.
When I try initiate Blowfish (line 23) I get error.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions