mirror of
https://github.com/arthur-pbty/portfolio2023.git
synced 2026-06-04 15:56:24 +02:00
25 lines
719 B
JavaScript
25 lines
719 B
JavaScript
"use strict";
|
|
/*
|
|
* @adonisjs/hash
|
|
*
|
|
* (c) Harminder Virk <virk@adonisjs.com>
|
|
*
|
|
* For the full copyright and license information, please view the LICENSE
|
|
* file that was distributed with this source code.
|
|
*/
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
class HashProvider {
|
|
constructor(app) {
|
|
this.app = app;
|
|
}
|
|
register() {
|
|
this.app.container.singleton('Adonis/Core/Hash', () => {
|
|
const config = this.app.container.resolveBinding('Adonis/Core/Config').get('hash', {});
|
|
const { Hash } = require('../src/Hash');
|
|
return new Hash(this, config);
|
|
});
|
|
}
|
|
}
|
|
exports.default = HashProvider;
|
|
HashProvider.needsApplication = true;
|