Commit graph

4203 commits

Author SHA1 Message Date
David Mehren
01b53d3858
fix(alias): remove default for primary
To make the create method more consistent with the
guidelines,
this commit removes the default value from the `primary` parameter.

Signed-off-by: David Mehren <git@herrmehren.de>
2021-11-14 21:46:04 +01:00
David Mehren
9258863dbd
fix(media-upload): remove backendData parameter
`Create` methods should only contain optional properties

Signed-off-by: David Mehren <git@herrmehren.de>
2021-11-14 21:46:04 +01:00
David Mehren
a08d8c58ed
fix(identity): remove default for syncSource
To make the create method more consistent with the
guidelines,
this commit removes the default value from the `syncSource` parameter.

An Identity will be created as sync source,
when the associated account is created using an external provider.

Signed-off-by: David Mehren <git@herrmehren.de>
2021-11-14 21:46:04 +01:00
David Mehren
5ba6b4ab67
fix(group): add special flag to create method
To make the create method more consistent with the
guidelines, this commit adds the `special` flag to
the parameters.
As this function will only be used to create the two hard-coded groups
and to handle API requests at one or two places, adding the parameter
should not be too problematic.

Signed-off-by: David Mehren <git@herrmehren.de>
2021-11-14 21:46:04 +01:00
Philip Molares
8c78656f8c docs: add dev documentation for create methods
Signed-off-by: Philip Molares <philip.molares@udo.edu>
2021-11-11 22:15:00 +01:00
Philip Molares
09f0d7c389 fix(media-upload): rework create and media services saveFile
This was done to make the create method more concise.

Signed-off-by: Philip Molares <philip.molares@udo.edu>
2021-11-11 22:07:20 +01:00
Philip Molares
d5c77613bb test(private-api): fix aliases expect
Signed-off-by: Philip Molares <philip.molares@udo.edu>
2021-11-11 22:07:20 +01:00
Philip Molares
58d8ff71fe fix: the tests use the new typing from create methods
Signed-off-by: Philip Molares <philip.molares@udo.edu>
2021-11-11 22:07:20 +01:00
Philip Molares
d18d23cb16 fix: services use the new typings from create methods
Signed-off-by: Philip Molares <philip.molares@udo.edu>
2021-11-11 22:07:20 +01:00
Philip Molares
b896f954b9 feat: consolidate entities create
This was done to give better typings to the function signatures of entities `create` methods.
It also ensures that each field that should be set to `null` is set to `null` and doesn't leave that up to the typeorm handlers.

See: #1641
Signed-off-by: Philip Molares <philip.molares@udo.edu>
2021-11-11 22:07:20 +01:00
Yannick Bungers
bb7561b9ad
Merge pull request #1794 from hedgedoc/addSpecialGroups 2021-11-08 21:11:07 +01:00
renovate[bot]
5ebdbd042e
chore(deps): update dependency eslint-plugin-jest to v25.2.4 (#1806)
Signed-off-by: Renovate Bot <bot@renovateapp.com>

Co-authored-by: Renovate Bot <bot@renovateapp.com>
2021-11-08 13:50:36 +00:00
renovate[bot]
bb21e912e8
chore(deps): lock file maintenance (#1805)
Signed-off-by: Renovate Bot <bot@renovateapp.com>

Co-authored-by: Renovate Bot <bot@renovateapp.com>
2021-11-08 03:51:24 +00:00
David Mehren
9b044d683a
Merge pull request #1803 from hedgedoc/renovate/develop-linters 2021-11-07 16:43:20 +01:00
Philip Molares
3291b43423 docs: fix createUser and test docs
this ports the fixes applied to createGroup to this method as well

Signed-off-by: Philip Molares <philip.molares@udo.edu>
2021-11-06 11:51:13 +01:00
Philip Molares
5d6863d03c feat: setupSpecialGroups in bootstrap
Signed-off-by: Philip Molares <philip.molares@udo.edu>
2021-11-06 11:51:13 +01:00
Philip Molares
b5ab3d830c fix: permissions service use new SpecialGroup enum
instead of random strings the permissions service now uses the SpecialGroup enum

Signed-off-by: Philip Molares <philip.molares@udo.edu>
2021-11-06 11:51:13 +01:00
Philip Molares
371c7dfe11 feat: add createGroup function
Signed-off-by: Philip Molares <philip.molares@udo.edu>
2021-11-06 11:51:13 +01:00
Renovate Bot
123128dfe6
chore(deps): update dependency eslint to v8.2.0
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-11-06 01:33:38 +00:00
renovate[bot]
faa982f119
chore(deps): update dependency eslint-plugin-jest to v25.2.3 (#1802)
Signed-off-by: Renovate Bot <bot@renovateapp.com>

Co-authored-by: Renovate Bot <bot@renovateapp.com>
2021-11-04 22:25:13 +00:00
David Mehren
f5c20ea716
Merge pull request #1800 from hedgedoc/renovate/develop-nestjs-packages 2021-11-04 19:41:12 +01:00
David Mehren
90919a956e
Merge pull request #1799 from hedgedoc/renovate/develop-linters 2021-11-04 19:40:02 +01:00
Renovate Bot
6a00cfff15
fix(deps): update dependency @nestjs/config to v1.1.0
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-11-03 19:13:18 +00:00
Renovate Bot
d8b065df3f
chore(deps): update linters to v5.3.0
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-11-03 19:13:02 +00:00
David Mehren
c4c12fb171
Merge pull request #1801 from hedgedoc/renovate/develop-trivago-prettier-plugin-sort-imports-3.x 2021-11-03 20:11:04 +01:00
Renovate Bot
035895339a
chore(deps): update dependency @trivago/prettier-plugin-sort-imports to v3.1.0
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-11-03 13:38:01 +00:00
renovate[bot]
5dafe3890d
chore(deps): lock file maintenance (#1798)
Signed-off-by: Renovate Bot <bot@renovateapp.com>

Co-authored-by: Renovate Bot <bot@renovateapp.com>
2021-11-01 05:10:41 +00:00
renovate[bot]
d279829dbd
fix(deps): update dependency node-fetch to v2.6.6 (#1796)
Signed-off-by: Renovate Bot <bot@renovateapp.com>

Co-authored-by: Renovate Bot <bot@renovateapp.com>
2021-10-31 18:03:26 +00:00
Philip Molares
4a717551b9 feat: add SpecialGroup enum
Signed-off-by: Philip Molares <philip.molares@udo.edu>
2021-10-30 23:58:17 +02:00
renovate[bot]
832702da9b
chore(deps): update dependency mkdocs-material to v7.3.6 (#1792)
Signed-off-by: Renovate Bot <bot@renovateapp.com>

Co-authored-by: Renovate Bot <bot@renovateapp.com>
2021-10-30 14:11:19 +00:00
Yannick Bungers
cf991decc0
Merge pull request #1787 from hedgedoc/enhancement/e2e_login_registration 2021-10-29 22:12:30 +02:00
renovate[bot]
a8a6c38176
fix(deps): update dependency @nestjs/config to v1.0.3 (#1788)
Signed-off-by: Renovate Bot <bot@renovateapp.com>

Co-authored-by: Renovate Bot <bot@renovateapp.com>
2021-10-28 10:50:31 +00:00
David Mehren
ef2e90da20
Add E2E tests for login and registration
Signed-off-by: David Mehren <git@herrmehren.de>
2021-10-28 10:19:48 +02:00
David Mehren
5a16047f50
AuthController: Return 409 Conflict when user already exists
The previously used HTTP error 400 'Bad Request' is not really
applicable here, as the client did not send a malformed message.

Signed-off-by: David Mehren <git@herrmehren.de>
2021-10-28 10:18:05 +02:00
David Mehren
3560d82c44
TestSetup: Initialize full app and session middleware
Signed-off-by: David Mehren <git@herrmehren.de>
2021-10-28 10:18:05 +02:00
renovate[bot]
297710fd62
chore(deps): update dependency mkdocs-material to v7.3.5 (#1786)
Signed-off-by: Renovate Bot <bot@renovateapp.com>

Co-authored-by: Renovate Bot <bot@renovateapp.com>
2021-10-28 00:32:07 +00:00
David Mehren
c10e033dea
Merge pull request #1784 from hedgedoc/renovate/develop-trivago-prettier-plugin-sort-imports-3.x 2021-10-27 18:05:40 +02:00
David Mehren
17dc2692f0
Merge pull request #1775 from hedgedoc/renovate/develop-lock-file-maintenance 2021-10-27 18:02:06 +02:00
David Mehren
5f04f3556a
Update .prettierrc for sort-imports v3
Signed-off-by: David Mehren <git@herrmehren.de>
2021-10-27 17:58:09 +02:00
Renovate Bot
640114612e
chore(deps): lock file maintenance
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-10-27 15:55:09 +00:00
Renovate Bot
d70d5675d2
chore(deps): update dependency @trivago/prettier-plugin-sort-imports to v3
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-10-27 15:49:54 +00:00
David Mehren
18822d60a8
Merge pull request #1773 from hedgedoc/renovate/develop-linters 2021-10-27 17:46:22 +02:00
Renovate Bot
443c2e8a1b
chore(deps): update linters
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-10-27 15:41:46 +00:00
David Mehren
85528cc016
Merge pull request #1772 from hedgedoc/renovate/develop-ts-node-10.x 2021-10-27 17:39:51 +02:00
Renovate Bot
05d7ba2b50
chore(deps): update dependency ts-node to v10.4.0
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2021-10-26 02:27:04 +00:00
renovate[bot]
2105cf78db
chore(deps): update dependency @types/node to v14.17.32 (#1781)
Signed-off-by: Renovate Bot <bot@renovateapp.com>

Co-authored-by: Renovate Bot <bot@renovateapp.com>
2021-10-26 02:25:34 +00:00
renovate[bot]
2e86058c1d
chore(deps): update dependency @types/node to v14.17.31 (#1779)
Signed-off-by: Renovate Bot <bot@renovateapp.com>

Co-authored-by: Renovate Bot <bot@renovateapp.com>
2021-10-25 20:10:08 +00:00
renovate[bot]
ddcb689a59
chore(deps): update dependency @types/node to v14.17.30 (#1778)
Signed-off-by: Renovate Bot <bot@renovateapp.com>

Co-authored-by: Renovate Bot <bot@renovateapp.com>
2021-10-25 17:43:30 +00:00
renovate[bot]
33203268a9
fix(deps): update nestjs packages to v8.1.2 (#1777)
Signed-off-by: Renovate Bot <bot@renovateapp.com>

Co-authored-by: Renovate Bot <bot@renovateapp.com>
2021-10-25 17:33:51 +00:00
Yannick Bungers
a06ffdd8c6
Merge pull request #1741 from hedgedoc/enhancement/faster_tests 2021-10-24 18:49:43 +02:00