@h3ravel/database 11.2.4 → 11.2.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +11 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +10 -0
- package/dist/index.js.map +1 -1
- package/package.json +4 -4
package/dist/index.cjs
CHANGED
|
@@ -11,6 +11,8 @@ let node_os = require("node:os");
|
|
|
11
11
|
node_os = require_chunk.__toESM(node_os);
|
|
12
12
|
let node_tty = require("node:tty");
|
|
13
13
|
node_tty = require_chunk.__toESM(node_tty);
|
|
14
|
+
let crypto = require("crypto");
|
|
15
|
+
crypto = require_chunk.__toESM(crypto);
|
|
14
16
|
let __h3ravel_arquebus_migrations = require("@h3ravel/arquebus/migrations");
|
|
15
17
|
__h3ravel_arquebus_migrations = require_chunk.__toESM(__h3ravel_arquebus_migrations);
|
|
16
18
|
let __h3ravel_core = require("@h3ravel/core");
|
|
@@ -12499,6 +12501,15 @@ var Resolver = class {
|
|
|
12499
12501
|
else if (pm === "bun") cmd = "create";
|
|
12500
12502
|
return `${pm} ${cmd} ${pkg}`;
|
|
12501
12503
|
}
|
|
12504
|
+
/**
|
|
12505
|
+
* Create a hash for a function or an object
|
|
12506
|
+
*
|
|
12507
|
+
* @param provider
|
|
12508
|
+
* @returns
|
|
12509
|
+
*/
|
|
12510
|
+
static hashObjectOrFunction(provider) {
|
|
12511
|
+
return crypto.default.createHash("sha1").update(provider.toString()).digest("hex");
|
|
12512
|
+
}
|
|
12502
12513
|
};
|
|
12503
12514
|
|
|
12504
12515
|
//#endregion
|