Commit Graph

27 Commits

Author SHA1 Message Date
Joas Schilling
aa5f037af7
chore: apply changes from Nextcloud coding standards 1.1.1
Signed-off-by: Joas Schilling <coding@schilljs.com>
Signed-off-by: Benjamin Gaussorgues <benjamin.gaussorgues@nextcloud.com>
2023-11-23 10:36:13 +01:00
Julius Härtl
614981ae9a
feat(directediting): Allow opening by file id
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2023-02-20 12:16:34 +01:00
Julius Härtl
47bc024885
Revert the token scope to not end up with storing the user used in the session
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2023-02-17 10:18:18 +01:00
Côme Chilliet
f5c361cf44
composer run cs:fix
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-01-20 11:45:08 +01:00
Azul
8535dc4255 fix translation source in directEditing templates
The 'Empty file' string is translated in `lib` - not in `core`.

Signed-off-by: Azul <azul@riseup.net>
2021-12-16 16:30:50 +01:00
John Molakvoæ (skjnldsv)
215aef3cbd
Update php licenses
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
2021-06-04 22:02:41 +02:00
Julius Härtl
37591f05dc
Get the parent directory before creating a file from a template
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2021-04-01 13:48:21 +02:00
Christoph Wurst
d9015a8c94
Format code to a single space around binary operators
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-10-05 20:25:24 +02:00
Julius Härtl
e0ae37745a
Do not expose direct editing if no master key is available
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2020-09-01 11:40:27 +02:00
Christoph Wurst
caff1023ea
Format control structures, classes, methods and function
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>
2020-04-10 14:19:56 +02:00
Christoph Wurst
41b5e5923a
Use exactly one empty line after the namespace declaration
For PSR2

Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-04-09 11:48:10 +02:00
Christoph Wurst
1a9330cd69
Update the license headers for Nextcloud 19
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-03-31 14:52:54 +02:00
Christoph Wurst
74936c49ea
Remove unused imports
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-03-25 22:08:08 +01:00
Robin Appelman
47fd6730e0
use nodeExists instead of catching exceptions
makes the intent of the code more clear imo

Signed-off-by: Robin Appelman <robin@icewind.nl>
2020-01-14 11:03:14 +01:00
Roeland Jago Douma
e7b308cf0a
Merge pull request #18805 from nextcloud/bugfix/direct-edit-create
Check if file already exists during file creation
2020-01-14 08:34:39 +01:00
Julius Härtl
ab4b9a6df5
CHeck if file already exists during file creation
Signed-off-by: Julius Härtl <jus@bitgrid.net>
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2020-01-13 18:10:12 +01:00
Christoph Wurst
6127c288e8 Fix license headers
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-01-13 14:23:49 +01:00
Christoph Wurst
4ff11e3955
Do not generate tokens for editor IDs that do not exist
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2019-12-19 09:38:22 +01:00
Julius Härtl
de5384466c
Return empty template for default creators
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2019-12-16 17:22:53 +01:00
Roeland Jago Douma
9a40ccfbf0
Merge pull request #18224 from nextcloud/bugfix/noid/direct-editing-path
Use file path for direct editing
2019-12-11 11:17:26 +01:00
Christoph Wurst
5bf3d1bb38
Update license headers
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2019-12-05 15:38:45 +01:00
Julius Härtl
e29a76bc79
Use file path for direct editing
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2019-12-05 09:54:58 +01:00
Julius Härtl
6c92e4d8ae
Check for boolean value
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2019-11-28 15:50:23 +01:00
Julius Härtl
9a2694fcb0
Code style fixes and cleanup
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2019-11-27 19:56:40 +01:00
Julius Härtl
bc36cc808f
Move editor list to capabilities
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2019-11-27 14:36:21 +01:00
tobiasKaminsky
bccf236738
encapsulate templates
Signed-off-by: tobiasKaminsky <tobias@kaminsky.me>
2019-11-27 14:36:20 +01:00
Julius Härtl
e52793c69e
Direct editing API to allow file editing using a one-time token for
mobile apps

Signed-off-by: Julius Härtl <jus@bitgrid.net>
2019-11-27 14:36:20 +01:00