Skip to content

Commit

Permalink
Remove unused exports
Browse files Browse the repository at this point in the history
  • Loading branch information
Veikkosuhonen committed Jan 18, 2024
1 parent e824318 commit d7912d3
Show file tree
Hide file tree
Showing 4 changed files with 2 additions and 20 deletions.
2 changes: 0 additions & 2 deletions src/auth/IAMConfig.js
Original file line number Diff line number Diff line change
Expand Up @@ -552,10 +552,8 @@ module.exports = {
dekaaniIamToFaculty,
iamToFaculty,
opetusVaradekaani,
getStudyLeaderGroup,
isStudyLeaderGroup,
relevantIAMs,
relevantOrganisations,
isKatselmusViewer,
ANY,
}
16 changes: 0 additions & 16 deletions src/auth/common.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,19 +42,3 @@ export const mapToDegreeCode = (organisationCode: string) => {
const code = `${masters ? 'M' : 'K'}H${start.substr(0, 2)}_${end.substr(-3)}`
return code
}

// Year starting month
const MONTH = 8

export const startOfStudyYear = (date: Date|string|number) => {
let d = null
if (typeof date !== 'object') {
d = new Date(date)
} else {
d = date
}

const year = d.getFullYear() - (d.getMonth() + 1 < MONTH ? 1 : 0)

return new Date(`${year}-${MONTH}-01`)
}
2 changes: 1 addition & 1 deletion tests/data.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
export const NO_RIGHTS_USER = {
const NO_RIGHTS_USER = {
id: 'user-1',
iamGroups: [],
}
Expand Down
2 changes: 1 addition & 1 deletion tests/utils.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
export const baseUrl = 'http://localhost:3000'
const baseUrl = 'http://localhost:3000'

export const api = {
get: async (endpoint) => {
Expand Down

0 comments on commit d7912d3

Please sign in to comment.