summaryrefslogtreecommitdiff
path: root/lib/migrations (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Add missing catchTilman Vatteroth2020-12-021-1/+2
| | | | Signed-off-by: Tilman Vatteroth <tilman.vatteroth@tu-dortmund.de>
* Catch more errorsTilman Vatteroth2020-12-029-10/+31
| | | | Signed-off-by: Tilman Vatteroth <tilman.vatteroth@tu-dortmund.de>
* [Migrations] Replace similar codeTilman Vatteroth2020-11-301-2/+1
| | | | Signed-off-by: Tilman Vatteroth <tilman.vatteroth@tu-dortmund.de>
* [Migrations] Add variant of error message to catch blockTilman Vatteroth2020-11-301-1/+4
| | | | Signed-off-by: Tilman Vatteroth <tilman.vatteroth@tu-dortmund.de>
* Add fix for missing deletion of notes on user-deletion requestSheogorath2020-03-211-0/+61
| | | | | | | | | | | | | | | | | | | | | | Depending on how the system was setup, this bug lead to keep user's data around even after a successful deletion of user'S account. This patch will make sure the missing database constraints are implemented and missed out deletions are executed. This bug was introduced to insufficent testing after implementing the feature initially. It was well tested, using the app process itself, but the migrations where missed out. I'm currently not sure, if there was also a change in how sequelize handles cassaded deletion, since I'm unter the impression that before switching to sequelize 5, this feature has worked. But I haven't verified this. No matter what, the cleanup process is rather straight forward and will be invoked on migration, but can also be done manually using the new `bin/cleanup` script. This change will result in a release 1.6.1. Signed-off-by: Sheogorath <sheogorath@shivering-isles.com>
* fix: migration should return promisechandi2019-08-123-18/+18
| | | | Signed-off-by: chandi <git@chandi.it>
* Fix eslint warningsSheogorath2019-05-3111-17/+26
| | | | | | | | | | | Since we are about to release it's time to finally fix our linting. This patch basically runs eslint --fix and does some further manual fixes. Also it sets up eslint to fail on every warning on order to make warnings visable in the CI process. There should no functional change be introduced. Signed-off-by: Sheogorath <sheogorath@shivering-isles.com>
* Update error message text checksCarles Bruguera2018-11-168-8/+8
| | | | Signed-off-by: Carles Bruguera <carlesba@gmail.com>
* Extend migration error handlingSheogorath2018-09-058-9/+9
| | | | | | | | | | The current error handling seems to conflict with some sequelize versions. So we add a second version of it in our excemptions. I'm not happy about it, but when it helps to prevent further migration breaking, it's worth it. Signed-off-by: Sheogorath <sheogorath@shivering-isles.com>
* Add missing catch blocks for migration from 1.1.1 to 1.2.0Hugo Caloto2018-07-318-2/+56
| | | | Signed-off-by: Hugo Caloto <hcaloto@gmail.com>
* Merge pull request #830 from SISheogorath/feature/GDPRChristoph (Sheogorath) Kern2018-06-171-0/+13
|\ | | | | GDPR compliant part 1
| * Add token based security featureSheogorath2018-05-251-0/+13
| | | | | | | | | | | | | | | | | | | | | | | | In the current setup users could be tricked into deleting their data by providing a malicious link like `[click me](/me/delete)`. This commit prevents such an easy attack and need the user's deleteToken to get his data deleted. In case someone requests his deletion by email you can also ask him for this token. We can add a GUI that shows it later on. Signed-off-by: Sheogorath <sheogorath@shivering-isles.com>
* | Use TEXT instead of STRING for tokensPedro Ferreira2018-03-261-0/+23
|/ | | | Signed-off-by: Pedro Ferreira <pedro.ferreira@cern.ch>
* Add missing migration for permissionsSheogorath2018-03-061-0/+11
| | | | Signed-off-by: Sheogorath <sheogorath@shivering-isles.com>
* Fix field type to prevent data truncation of authorship (#721)Max Wu2018-02-091-0/+13
| | | | * Fix field type to prevent data truncation of authorship
* Fix typo of DB migration scriptTakeaki Matsumoto2018-02-081-2/+2
| | | | Signed-off-by: Takeaki Matsumoto <takeaki.matsumoto@ntt.com>
* Fix #521 by converting content fields to LONGTEXT in MySQL, to prevent ↵Claudius Coenen2017-10-161-0/+16
| | | | truncation of data.
* fix: Other dialect duplicated add index problemBoHong Li2017-03-281-3/+9
| | | | Detect is using SQLite to add index
* fix: Support SQliteBoHong Li2017-03-283-7/+25
| | | | Move 'unique' constraint to another statement (SQLite don't support set unique when addColumn)
* fix: Add missing migrationBoHong Li2017-03-277-0/+139
|
* fix: Fixed sequelize-cli db:migration cannot stop when occur errorBoHong Li2017-03-245-41/+51
| | | | | | Up and Down method must return a Promise. breaking changes: docker-hackmd cannot initialize, because db:migration will fail
* Use strict mode in all backend filesBoHong Li2017-03-145-0/+5
| | | | add ‘use strict’ in all backend file
* Use JavaScript Standard StyleBoHong Li2017-03-085-45/+29
| | | | | Introduce JavaScript Standard Style as project style rule, and fixed all fail on backend code.
* Fix redundant parameter to removeColumn in db migration scriptsWu Cheng-Han2017-01-212-3/+3
|
* Fix migration script of revision lacks of definition of primary keyWu Cheng-Han2017-01-021-1/+4
|
* Update to support optional email register and signinWu Cheng-Han2016-12-021-0/+13
|
* Update to support delete noteWu Cheng-Han2016-10-101-0/+11
|
* Add support of saving authors and authorshipWu Cheng-Han2016-07-301-0/+28
|
* Add support of saving note revision and improve app start and stop procedure ↵Cheng-Han, Wu2016-06-171-0/+24
| | | | to ensure data integrity
* Add db migrations for PR #121Cheng-Han, Wu2016-05-151-0/+15