Files
planka/server/api/helpers/utils/hash.js
2025-11-06 20:56:48 +01:00

22 lines
396 B
JavaScript

/*!
* Copyright (c) 2024 PLANKA Software GmbH
* Licensed under the Fair Use License: https://github.com/plankanban/planka/blob/master/LICENSE.md
*/
const crypto = require('crypto');
module.exports = {
sync: true,
inputs: {
data: {
type: 'ref',
required: true,
},
},
fn(inputs) {
return crypto.createHash('sha256').update(inputs.data).digest('hex');
},
};