Corrige la déclaration de la méthode getChecksum
Ajoute la spécification de retour pour la méthode getChecksum dans StorageService. Cela améliore la clarté et la sécurité du code en explicitant le type de retour attendu.
This commit is contained in:
parent
f0a950f16a
commit
53c7938304
@ -31,7 +31,7 @@ export class StorageService {
|
||||
* @param {Buffer} file - The file for which the checksum is to be calculated.
|
||||
* @return {string} - The hexadecimal representation of the checksum.
|
||||
*/
|
||||
private getChecksum(file: Buffer) {
|
||||
private getChecksum(file: Buffer): string {
|
||||
return crypto.createHash('sha256').update(file).digest('hex').toLowerCase();
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user