Skip to content
This repository was archived by the owner on Aug 29, 2018. It is now read-only.

Commit 5418f69

Browse files
authored
Rename repository and use npm scope (#38)
* Rename repository and use npm scope * Update Codeclimate token and dependencies * Update package-lock.json
1 parent a8cecb2 commit 5418f69

9 files changed

Lines changed: 662 additions & 560 deletions

File tree

.travis.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ node_js:
44
- '6'
55
addons:
66
code_climate:
7-
repo_token: e343c2f43b67fdeaad91aa90c6010f2330d9440595c8337d7d757d0aa6cd25ae
7+
repo_token: 7b59b3fb1686f11b94d458292f5152bc81d7b7f30650a0a5bc36ac18bc009f76
88
notifications:
99
slack:
1010
rooms:

README.md

Lines changed: 13 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,25 @@
1-
# feathers-authentication-local
1+
# @feathersjs/authentication-local
22

3-
[![Greenkeeper badge](https://badges.greenkeeper.io/feathersjs/feathers-authentication-local.svg)](https://greenkeeper.io/)
3+
[![Greenkeeper badge](https://badges.greenkeeper.io/feathersjs/authentication-local.svg)](https://greenkeeper.io/)
44

5-
[![Build Status](https://travis-ci.org/feathersjs/feathers-authentication-local.png?branch=master)](https://travis-ci.org/feathersjs/feathers-authentication-local)
6-
[![Code Climate](https://codeclimate.com/github/feathersjs/feathers-authentication-local/badges/gpa.svg)](https://codeclimate.com/github/feathersjs/feathers-authentication-local)
7-
[![Test Coverage](https://codeclimate.com/github/feathersjs/feathers-authentication-local/badges/coverage.svg)](https://codeclimate.com/github/feathersjs/feathers-authentication-local/coverage)
8-
[![Dependency Status](https://img.shields.io/david/feathersjs/feathers-authentication-local.svg?style=flat-square)](https://david-dm.org/feathersjs/feathers-authentication-local)
9-
[![Download Status](https://img.shields.io/npm/dm/feathers-authentication-local.svg?style=flat-square)](https://www.npmjs.com/package/feathers-authentication-local)
5+
[![Build Status](https://travis-ci.org/feathersjs/authentication-local.png?branch=master)](https://travis-ci.org/feathersjs/authentication-local)
6+
[![Test Coverage](https://api.codeclimate.com/v1/badges/d948ae0f5b7572578d5a/test_coverage)](https://codeclimate.com/github/feathersjs/authentication-local/test_coverage)
7+
[![Dependency Status](https://img.shields.io/david/feathersjs/authentication-local.svg?style=flat-square)](https://david-dm.org/feathersjs/authentication-local)
8+
[![Download Status](https://img.shields.io/npm/dm/@feathersjs/authentication-local.svg?style=flat-square)](https://www.npmjs.com/package/@feathersjs/authentication-local)
109

1110
> Local authentication strategy for feathers-authentication using Passport without all the boilerplate.
1211
1312
## Installation
1413

1514
```
16-
npm install feathers-authentication-local --save
15+
npm install @feathersjs/authentication-local --save
1716
```
1817

19-
**Note:** This is only compatibile with `feathers-authentication@1.x` and above.
18+
**Note:** This is only compatibile with `@feathers/authentication@1.x` and above.
2019

2120
## Documentation
2221

23-
<!-- Please refer to the [feathers-authentication-local documentation](http://docs.feathersjs.com/) for more details. -->
22+
<!-- Please refer to the [@feathersjs/authentication-local documentation](http://docs.feathersjs.com/) for more details. -->
2423

2524
## API
2625

@@ -32,7 +31,7 @@ This module contains 3 core pieces:
3231

3332
### Main Initialization
3433

35-
In most cases initializing the `feathers-authentication-local` module is as simple as doing this:
34+
In most cases initializing the `@feathersjs/authentication-local` module is as simple as doing this:
3635

3736
```js
3837
app.configure(authentication(settings));
@@ -92,7 +91,7 @@ The `Verifier` class can be extended so that you customize it's behavior without
9291
An example of customizing the Verifier:
9392
9493
```js
95-
import local, { Verifier } from 'feathers-authentication-local';
94+
import local, { Verifier } from '@feathersjs/authentication-local';
9695

9796
class CustomVerifier extends Verifier {
9897
// The verify function has the exact same inputs and
@@ -122,7 +121,7 @@ By default, this strategy expects a payload in this format:
122121
123122
## Complete Example
124123
125-
Here's a basic example of a Feathers server that uses `feathers-authentication-local`. You can see a fully working example in the [example/](./example/) directory.
124+
Here's a basic example of a Feathers server that uses `@feathersjs/authentication-local`. You can see a fully working example in the [example/](./example/) directory.
126125
127126
```js
128127
const feathers = require('feathers');
@@ -132,7 +131,7 @@ const memory = require('feathers-memory');
132131
const bodyParser = require('body-parser');
133132
const errorHandler = require('feathers-errors/handler');
134133
const auth = require('feathers-authentication');
135-
const local = require('feathers-authentication-local');
134+
const local = require('@feathersjs/authentication-local');
136135

137136
// Initialize the application
138137
const app = feathers()

example/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
# feathers-authentication-local Example
1+
# @feathersjs/authentication-local Example
22

3-
This provides a complete working example on how to use `feathers-authentication-local` to provide local authentication and get a JWT access token in return.
3+
This provides a complete working example on how to use `@feathersjs/authentication-local` to provide local authentication and get a JWT access token in return.
44

55
1. Start the app by running `npm start`
66
2. Make a request using the authenticated user.

lib/hooks/hash-password.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ const hasher = require('../utils/hash');
22
const merge = require('lodash.merge');
33
const Debug = require('debug');
44

5-
const debug = Debug('feathers-authentication-local:hooks:hash-password');
5+
const debug = Debug('@feathersjs/authentication-local:hooks:hash-password');
66

77
module.exports = function hashPassword (options = {}) {
88
return function (hook) {

lib/index.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ const DefaultVerifier = require('./verifier');
77

88
const passportLocal = require('passport-local');
99

10-
const debug = Debug('feathers-authentication-local');
10+
const debug = Debug('@feathersjs/authentication-local');
1111
const defaults = {
1212
name: 'local',
1313
usernameField: 'email',
@@ -27,7 +27,7 @@ module.exports = function init (options = {}) {
2727
const _super = app.setup;
2828

2929
if (!app.passport) {
30-
throw new Error(`Can not find app.passport. Did you initialize feathers-authentication before feathers-authentication-local?`);
30+
throw new Error(`Can not find app.passport. Did you initialize feathers-authentication before @feathersjs/authentication-local?`);
3131
}
3232

3333
let name = options.name || defaults.name;

lib/verifier.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ const bcrypt = require('bcryptjs');
33
const get = require('lodash.get');
44
const omit = require('lodash.omit');
55

6-
const debug = Debug('feathers-authentication-local:verify');
6+
const debug = Debug('@feathersjs/authentication-local:verify');
77

88
class LocalVerifier {
99
constructor (app, options = {}) {
@@ -12,7 +12,7 @@ class LocalVerifier {
1212
this.service = typeof options.service === 'string' ? app.service(options.service) : options.service;
1313

1414
if (!this.service) {
15-
throw new Error(`options.service does not exist.\n\tMake sure you are passing a valid service path or service instance and it is initialized before feathers-authentication-local.`);
15+
throw new Error(`options.service does not exist.\n\tMake sure you are passing a valid service path or service instance and it is initialized before @feathersjs/authentication-local.`);
1616
}
1717

1818
this._comparePassword = this._comparePassword.bind(this);

0 commit comments

Comments
 (0)