Skip to content

Commit

Permalink
docs: improve return type of getFirstDay()
Browse files Browse the repository at this point in the history
Signed-off-by: Richard Steinmetz <richard@steinmetz.cloud>
  • Loading branch information
st3iny committed Jul 22, 2024
1 parent 524d060 commit f1036d7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/date.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ declare let window: Nextcloud.v27.WindowWithGlobals
/**
* Get the first day of the week
*
* @return {number}
* @return {number} The first day where 0 is Sunday, 1 is Monday etc.
*/
export function getFirstDay(): number {
export function getFirstDay(): 0 | 1 | 2 | 3 | 4 | 5 | 6 {
if (typeof window.firstDay === 'undefined') {
console.warn('No firstDay found')
return 1
Expand Down

0 comments on commit f1036d7

Please sign in to comment.