mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2025-05-19 09:45:37 -04:00
NotesService: Finished hardcoded functions
Signed-off-by: Philip Molares <philip.molares@udo.edu>
This commit is contained in:
parent
8b29e32e45
commit
4332b039d6
2 changed files with 117 additions and 65 deletions
9
src/utils/arrayDuplicatCheck.ts
Normal file
9
src/utils/arrayDuplicatCheck.ts
Normal file
|
@ -0,0 +1,9 @@
|
|||
/*
|
||||
* SPDX-FileCopyrightText: 2021 The HedgeDoc developers (see AUTHORS file)
|
||||
*
|
||||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
*/
|
||||
|
||||
export function checkArrayForDuplicates<T>(array: Array<T>): boolean {
|
||||
return new Set(array).size !== array.length;
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue