summaryrefslogtreecommitdiffstats
path: root/lib/private/DB/Adapter.php
Commit message (Collapse)AuthorAgeFilesLines
* Fix Exception catching in OC\DB\AdapterCôme Chilliet2023-09-051-2/+6
| | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* Cleanup plsam issues in DB/ContactsManager and ConsoleCarl Schwan2023-09-051-1/+1
| | | | Signed-off-by: Carl Schwan <carl@carlschwan.eu>
* composer run cs:fixCôme Chilliet2023-01-201-1/+0
| | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* Check style updateCarl Schwan2022-01-131-1/+1
| | | | Signed-off-by: Carl Schwan <carl@carlschwan.eu>
* Update php licensesJohn Molakvoæ (skjnldsv)2021-06-041-2/+0
| | | | Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
* Add our own DB exception abstractionChristoph Wurst2021-01-121-1/+9
| | | | | | | | | | | | | | | | | | Right now our API exports the Doctrine/dbal exception. As we've seen with the dbal 3 upgrade, the leakage of 3rdparty types is problematic as a dependency update means lots of work in apps, due to the direct dependency of what Nextcloud ships. This breaks this dependency so that apps only need to depend on our public API. That API can then be vendor (db lib) agnostic and we can work around future deprecations/removals in dbal more easily. Right now the type of exception thrown is transported as "reason". For the more popular types of errors we can extend the new exception class and allow apps to catch specific errors only. Right now they have to catch-check-rethrow. This is not ideal, but better than the dependnecy on dbal. Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Bump doctrine/dbal from 2.12.0 to 3.0.0Christoph Wurst2021-01-081-2/+2
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Format code to a single space around binary operatorsChristoph Wurst2020-10-051-1/+1
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Remove @suppress SqlInjectionCheckerMorris Jobke2020-09-161-3/+0
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Update license headers for 19Christoph Wurst2020-04-291-0/+1
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Format control structures, classes, methods and functionChristoph Wurst2020-04-101-3/+3
| | | | | | | | | | | | | | | To continue this formatting madness, here's a tiny patch that adds unified formatting for control structures like if and loops as well as classes, their methods and anonymous functions. This basically forces the constructs to start on the same line. This is not exactly what PSR2 wants, but I think we can have a few exceptions with "our" style. The starting of braces on the same line is pracrically standard for our code. This also removes and empty lines from method/function bodies at the beginning and end. Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Update license headersChristoph Wurst2019-12-051-1/+3
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Fix PHPDocMorris Jobke2019-03-211-1/+1
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Code cleanup.Ole Ostergaard2019-03-211-2/+2
| | | | Signed-off-by: Ole Ostergaard <ole.c.ostergaard@gmail.com>
* Add supression of SqlInjectionChecker.Ole Ostergaard2019-03-211-0/+3
| | | | Signed-off-by: Ole Ostergaard <ole.c.ostergaard@gmail.com>
* Add insertIgnoreConflict to Adapter and use it for for executing the file ↵Ole Ostergaard2019-03-211-0/+13
| | | | | | locking. Signed-off-by: Ole Ostergaard <ole.c.ostergaard@gmail.com>
* Add deprecation message ofr insertIfNotExistMorris Jobke2018-11-091-0/+1
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Catch UniqueConstraintViolationException inside insertIfNotExistMorris Jobke2018-11-091-2/+14
| | | | | | | | This is the most common case for the usage of this method. See also https://github.com/nextcloud/server/issues/12369 and the linked tickets. Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Use short for of substr to not need strlen()Morris Jobke2018-01-251-1/+1
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Update with robinJoas Schilling2016-07-211-1/+1
|
* Fix othersJoas Schilling2016-07-211-2/+3
|
* Add a method to lock a tableJoas Schilling2016-05-211-0/+20
|
* Move \OC\DB to PSR-4Roeland Jago Douma2016-04-151-0/+95
Besides the statement wrapper that is moved to the legacy folder (namepsace of shame folder)