7fa2418e54
[PLUGINS][Oomox] Theme colours WIP.
2021-11-26 14:45:28 +00:00
6cd7be6abc
[UI][CONTROLLER][ENTITY][DOCS] Refactor term 'timeline' into 'feed'
2021-11-26 13:05:23 +00:00
283820a4a5
[UI][ENTITY][Language] Use list rather than hashmap so actor language ordering is preserved
2021-11-26 12:30:21 +00:00
04e6b2fb53
[ENTITY][Language] Properly handle context actor language
2021-11-26 12:29:27 +00:00
edf1b30e89
[TOOLS][DOCS] Add missing doc blocks
2021-11-25 23:16:04 +00:00
b1262919da
[TOOLS] Fix (most) issues found by PHPStan
2021-11-25 23:08:30 +00:00
98b719dca3
[COMPONENTS][Tag] Split tag into words and stem each
2021-11-25 20:37:53 +00:00
2d057024b9
[TAGS][ENTITY][Note] Properly store the note language, pass it along when rendering content. Add mechanism for stemming tags, with fallback to simply slug-ifying them
2021-11-25 20:37:53 +00:00
f837df5753
[CACHE] Add way of calculating hash map if key is not found
2021-11-25 20:37:53 +00:00
c1779dc12d
[UI] Don't display short language form in user panel language selection
2021-11-25 20:37:53 +00:00
0194b6b14c
[TESTS] Fix tests by adding missing is_local columns and by login in the admin user in the admin panel test
2021-11-25 20:37:52 +00:00
d9544c6edb
[CORE][SECURITY] Move to the new authentication format, for Symfony 5.3
2021-11-25 20:37:45 +00:00
05758c999f
[ENTITY][Actor] fix typo in findRelativeActors query
2021-11-25 02:07:12 +00:00
d8147cbd2d
[PLUGINS][AttachmentShowRelated] Fixed note template error. Fixed if statement.
...
[CORE][Controller] Commented CSP out.
2021-11-24 12:46:32 +00:00
8edaabbabf
[TWIG][Settings] WIP Refactoring of user panel. Now using macros to diminish repeated code.
...
[CONTROLLER][UserPanel] Replaced form names. More readable.
2021-11-24 12:46:31 +00:00
30f4131f5d
[TESTS] Add missing 'is_local' to actors in data fixtures
2021-11-24 12:46:31 +00:00
206856e1ba
[FORM][FormFields] Add way of specifying attributes for password fields (namely form autocomplete=new-password)
2021-11-24 12:46:31 +00:00
3a5e52ee0d
[CORE][SECURITY] Move to the new authentication format, for Symfony 5.3
...
Keep using (deprecated) Guard
2021-11-24 12:46:26 +00:00
b4ce77320e
[TESTS] Fix remaining tests, back to 100% passed. Some minor semantic changes
2021-11-20 21:33:25 +00:00
c68d7ae406
[CONTROLLER][UserPanel] Make function names camelCase
2021-11-20 21:33:25 +00:00
7e4a971fac
[ENTITY][LocalUser][CACHE] Remove bad keys from getByNickname cache key
2021-11-20 21:33:25 +00:00
0e104a9701
[UTIL][HTML][TESTS] Fix test and implementation and expand HTML generation utilities
2021-11-20 21:33:25 +00:00
fe755f7c42
[UTIL][FormFields] Accomodate use of FormFields::repeated_password without a 'required' option
2021-11-20 21:33:23 +00:00
0aa43783e8
[PLUGIN][Repeat] Repeat now repeats attachments as it should.
...
[COMPONENTS][Posting] Now accepts attachments already processed.
[ENTITY][Note] Added getAttachmentsWithTitle().
2021-11-17 17:14:15 +00:00
8077bdb0b5
[CORE][Controller] CSP default-src changed to 'self' to allow internal redirects.
2021-11-17 01:29:36 +00:00
1d31bd651e
[CORE][Controller] Added Content-Security-Policy response header.
2021-11-17 00:49:23 +00:00
f07dce4604
[UTIL][Form] Fix bug with repeated_password
2021-11-16 23:27:29 +00:00
89d36a68e5
[ENTITY][Actor] Add is_local, it's common to depend, and this makes it much faster, with a low space cost
2021-11-16 23:26:20 +00:00
b8b19abed2
[ENTITY][AttachmentThumbnail] Do not attempt to check if a file exists if the path is null
2021-11-15 19:25:52 +00:00
5cafc80d01
[UTIL][FormFields] Refactor duplicated language choice form entry logic
2021-11-15 19:25:52 +00:00
e6c0db9ee1
[CORE][Cache] Allow retrieving multiple keys from a hashmap
2021-11-15 19:25:52 +00:00
587d701d11
[CONTROLLER][Network] Temporarily remove replies from streams, following planned changes to the Reply plugin
2021-11-15 19:25:52 +00:00
774eb49af4
[UI][CONTROLLER][UserPanel][ENTITY][ActorLanguage][Language][Actor] Add interface to allow user to select thier preferred languages and to order them. Rename ActorLanguage::order to ordering
2021-11-15 19:25:52 +00:00
d5e6fd603d
[CONTROLLER][UserPanel] Fix 'could not convert IntergetType to string' error
2021-11-15 19:25:51 +00:00
1abd28c949
[UI][TWIG][CONTROLLER][UserPanell] Add way to expand details with a GET parameter. Implement it in UserPanel
2021-11-15 19:25:51 +00:00
c509692102
[ENTITY][AttachmentThumbnail] Uncache when deleting, cleanup code and ensure the biggest thumbnail is used when the original is not avaliable
2021-11-15 19:25:51 +00:00
a3074662b8
[TESTS] Remove 'reply_to' in note creation in data fixtures
2021-11-15 19:25:51 +00:00
eab6de3609
[TESTS][Security] Fix SecurityTest. Remove nickname normalization on register (a plugin can handle that). Move from filter_var(FILTER_VALIDATE_EMAIL) as it does not support dotless domains
2021-11-15 19:25:50 +00:00
bf5ffe7d3d
[CACHE][TEST] Fix errors in cache implementation found by tests
2021-11-15 19:25:44 +00:00
98352cfece
[TESTS] Properly provide both createClient and bootKernel in test base class
2021-11-11 12:39:36 +00:00
2239845a00
[CONTROLLER][Security] Remove nickname normalization when trying to login
2021-11-11 12:39:36 +00:00
a1c78696f7
[CORE][Actor][Posting] Fixup Actor::getPreferredLanguageChoices following changes in how the data is cached
2021-11-11 12:39:36 +00:00
f39f800a8e
[TESTS] Add now-required content-type to notes created in data fixtures
2021-11-11 12:39:35 +00:00
f667b558f7
[TESTS] Fix SecurityTest
...
This test was broken by changes in the routing and in the templates.
However, this revealead a potential open redirect and duplicated code
in the Reply and Favourite plugins
2021-11-11 12:39:28 +00:00
dea9aa4dcf
[CORE][Router] Remove duplicate service for URL generation, as that is actually the same object
2021-11-11 12:38:09 +00:00
d0f9fde7c2
[PLUGIN][Reply] WIP. Note complementary info now shows who has replied on the original note!
2021-11-10 15:44:28 +00:00
f2f1bdc145
[PLUGIN][Reply] Separated replies from Note table.
...
[PLUGIN][Repeat] Deleted unnecessary card note template, info now to
appended at the end of note.
[PLUGIN][TreeNotes] WIP to accomodate reply plugin changes.
[TWIG][Runtime] Removed getAdditionalTemplateVars event.
2021-11-10 13:29:53 +00:00
7d8819a3da
[DB][CONTROLLER][Network][ENTITY][Note] Fix Note::getAllNotes
2021-11-09 23:38:37 +00:00
f0c532340e
[DB] Fix uses of DB::sql
, to remove the deprecated second entities
parameter
2021-11-08 20:35:38 +00:00
767b2035e7
[ENTITY][ActorLanguage] Remove duplicate specification of 'not null' in table schema
2021-11-08 20:32:10 +00:00
1d84f1629e
[CORE][DB] Make DB::sql not error when selecting from tables with columns of the same name and remove the second enitites paramter, calculating it internally instead
2021-11-08 20:32:10 +00:00
f98afd15ce
[ENTITY] Refactor Follow as Subscription
2021-11-08 16:14:23 +00:00
68c6dd1ba9
[CORE][Cache] Use hashmaps to store language related items
2021-11-08 16:08:04 +00:00
2eb31952bc
[ENTITY][Language] Use varchar as char leads to a padded string, which isn't helpful
2021-11-08 16:08:03 +00:00
2cf3a0b4e6
[COMPONENT][Posting] Display short language signifier rather than the full name for the first preffered language
2021-11-08 16:08:03 +00:00
705bf815ab
[CACHE] Add partial implmentation for caching hashmaps (non-list arrays, i.e. array<string,string>). No non-redis-fallback yet
2021-11-08 16:08:03 +00:00
cd470cbf93
[CORE] Fix loading of settings from modules
2021-11-08 16:08:03 +00:00
019ad794d1
[Posting] Add dropdown with language choice, with preferred choice according to user choice and context (group, etc)
2021-11-08 16:08:02 +00:00
9444c34071
[ENTITY][Actor][ActorLanguage][Language] Remove Actor::preferred_lang_id. Add ActorLanguage::order. Add Language::{short_display,long_display}. Instead of an actor having a single preffered language, the entries in ActorLanguage should be used, sorted by ActorLanguage::order
2021-11-08 16:08:02 +00:00
2bd05fbd47
[TOOLS][COMMAND] Add 'app:populate_initial_values' command, which inserts values into the language table if it does not yet contain values. Add database-force-nuke to Makefile, which does all the steps necessary to reset the database
2021-11-08 16:08:02 +00:00
1960f6944f
[CORE][DB] Fix error in regex that prevented selecting collumns that are named the same way a column is
2021-11-02 11:14:59 +00:00
839fa070c7
[CORE][Posting] Default Posting language to site language, if the user hasn't selected one
2021-11-02 11:14:59 +00:00
cf09b48e92
[PLUGINS][Repeat] Added note_repeat entity, fixed visual discrepancies, and completed the expected functionality.
...
[ENTITY][Note] Removed repeat_off from table. It is now part of the Repeat plugin.
2021-11-01 21:19:56 +00:00
712d1739e4
[UTIL][Formatting] Make local mentions great again
2021-11-01 12:16:29 +00:00
91dd6e1428
[Controller][Security] Fullname is not setup automatically upon registering anymore.
...
[ENTITY][Actor] Changes to accomodate fullname from potentially being null.
[ENTITY][Note] Changes to accomodate fullname from potentially being null.
2021-10-29 22:05:10 +01:00
9a23e03330
[PLUGINS][Repeat] Repeat template override WIP.
2021-10-29 17:26:20 +01:00
44454ac28a
[UTIL][TemporaryFile] Ensure resource
is neither false
nor null
when attempting to cleanup, otherwise getRealPath
returns false
and we get sad
2021-10-28 17:36:02 +01:00
458c09485a
[CORE][ENTITY] Move preferred language setting from [LocalUser] to [Actor], make [Language] language
unique and make [Note] content_type
not null
2021-10-28 17:34:01 +01:00
e6c5312025
[CORE][GSFile] Add check_is_supported_mimetype
option to GSFile::storeFileAsAttachment
2021-10-28 17:29:57 +01:00
c352e40518
[CORE][Controller] Allow plugins to override the Twig templates
2021-10-28 14:29:34 +01:00
18aeeb3850
[ENTITY] Add a [Language] table, which has a char 64 field that maps to an int. This is then used in [Note], [LocalUser] and [ActorLanguage]
2021-10-28 11:26:34 +01:00
e54e55dfbf
[EXCEPTION][RedirectException] You are now able to redirect to a specific url.
2021-10-27 20:44:50 +01:00
3e2fefa8af
[TWIG][Cards] Fullname is now displayed as the note author, nickname as an identification.
...
[CONTROLLER][Security] Fullname is set on resgistration to enable it to be shown by default in notes.
[CONTROLLER][UserPanel] Fullname extra step added.
[CSS] Fullname and nickname representation work.
2021-10-27 20:44:50 +01:00
3cdaf6671a
[CORE][HTTPClient] Add some shortcut functions inspired by pre-v3
2021-10-27 04:22:18 +01:00
3227e1f919
[CORE][Log] Document magic methods
2021-10-27 04:22:18 +01:00
bccafd0d7b
[CORE][GSFile] Respect mimetype whitelist and extensions blacklist before saving files
2021-10-27 04:19:33 +01:00
8038fdbce9
[UTIL][Common] Added Common::getUploadLimit().
...
[COMPONENT][Posting] Update Posting to warn the user of submtting attachments too large.
2021-10-27 04:19:32 +01:00
656c2c7812
[SECURITY][Authenticator] fix wrong route id on after login redirection
2021-10-27 04:19:32 +01:00
299e893ca9
[TOOLS][PHPStan][DocCheck] Fix errors found by PHPStan and Doc Check
2021-10-27 04:19:31 +01:00
dff5647b97
[DB][Note] Add langauge field to notes
2021-10-27 04:19:31 +01:00
8a10fec31d
[CONTROLLER][UserPanel] Make all fields in settings not required
2021-10-27 04:19:30 +01:00
2694d83ae4
[TOOLS][CS-FIXER] Run new PHP CS Fixer config. Notably, adds strict_types
2021-10-27 04:19:30 +01:00
028ea79fff
[CORE][Router] Properly act on Accept headers
2021-10-27 04:19:30 +01:00
99fd2f725b
[Core][Util] Hotfix: In App\Core\DB\DB persistWithSameId, casting the id to an int. In App\Util\HTML html, tag is now evaluated beforehand, making sure it's a string.
2021-10-27 04:19:30 +01:00
8fdc52636f
[ActivityPub] Port RSA
2021-10-27 04:19:29 +01:00
8544fe157b
[FreeNetwork] First steps porting webfinger/lrdd to v3, GET webfinger requests already have a basic result
2021-10-27 04:19:29 +01:00
44cf1fa24c
[UTIL][Nickname] Fix some parameters issues found with strict types
2021-10-27 04:19:29 +01:00
b524c5bc90
[TOOLS][PHPStan] Add missing toString on the call to DB::filterName, as it seems something changed in some update
2021-10-27 04:19:28 +01:00
b65ee4c21d
[TOOLS][CS-FIXER] Fix incorrect transformation
2021-10-27 04:19:28 +01:00
9109c61af5
[TOOLS][CS-FIXER] Run new PHP CS Fixer config. Notably, adds strict_types
2021-10-27 04:19:28 +01:00
d575f8aef5
[UTIL][Formatting] Make it possible to supply string|array to either or both argument of Formatting::{starts,ends}With
2021-10-27 04:19:26 +01:00
99ab24ec23
[CORE][Controller] Allow routes without text/html response
...
Improve GET getters
2021-10-27 04:19:23 +01:00
03f6029ce5
[SECURITY] Fix nickname validation and properly allow email auth
2021-10-18 13:22:55 +01:00
071b769997
[CORE][Util][Common] Correct behaviour for absense of value
2021-10-18 13:22:45 +01:00
517ed953f2
[FreeNetwork] First step towards de-duplication mechanism for federation
...
Refactored AS2 inside AP; [ENTITY][Activity] went from core to AP
Webfinger plugin will be part of FreeNetwork component
2021-10-06 11:48:22 +01:00
3cb6563c40
[TWIG][EndShowStyles] Route as an event argument
2021-10-06 00:34:27 +01:00
17a13b3f20
[CSS] Fix: Left and right panel checkbox border when active.
2021-10-04 12:31:06 +01:00
80d1be323d
[COMPONENTS][Search][CSS] Extra header forms now accessible through a details element. Re-organizing templates structure.
2021-10-04 12:17:14 +01:00
d38ad60c76
[COMPONENTS][CSS] Adding components styling properly.
2021-10-01 17:25:51 +01:00
19c2a91232
[TOOLS][PHPStan][ProfileColor][ENTITY][TEST][AttachmentThumbnail] Fix issues reported by phpstan
2021-09-27 19:50:56 +01:00
1107d8257d
[TWIG] Add instanceof
test
...
Use with:
{% if var is instanceof(Namespace\Class) %}
2021-09-27 19:50:56 +01:00
2d8b220e92
[CORE][Controller] Make Controller abstract, handle
an optional non static method and use static::class
rather than get_called_class
2021-09-27 19:50:56 +01:00
a681acae67
[ENTITY][AttachmentThumbnail] Every image should have width and height attributes
2021-09-25 19:40:11 +01:00
3268559f9a
[AttachmentThumbnail] Use other thumbnail when requested isn't available and there's no original file
2021-09-23 16:19:50 +01:00
af3531f1c7
[CORE][GSFile] Add type annotation to the $encoders
used in attachment handling
2021-09-23 14:54:21 +01:00
21e598d877
[ENTITY][Actor] Fix issue with deleting a self tag
2021-09-23 14:34:34 +01:00
4820a863a9
[Avatar] Fix cache usage and other minor bugs
2021-09-23 14:34:34 +01:00
a557ba0224
[Timelines][Plugins][Left] Plugins now provide their path ID. Feed redone as it's own independant template.
2021-09-22 16:47:06 +01:00
05f16a3084
[ENTITY][AttachmentThumbnail] Now thumbnails are always only available in three sizes: small, medium, big
...
Commit jointly produced with eli (Eliseu Amaro)
Breaking change: Entity changed to only store the tinyint referring to the size stored
With this, the logic was simplified and now it's not possible to make an
instance produce unnecessary thumbs. The aspect ratio is preserved and
thus the thumbs will always look nice. New configuration was added to
maintain flexibility.
2021-09-22 15:13:46 +01:00
7beb5c2995
[GSFile] Fix sanitize configuration
2021-09-22 15:13:46 +01:00
69e7dc44bd
[ENTITY][Note] Change isVisibleTo
to allow for not supplying an actor
2021-09-21 16:38:50 +01:00
879f54c772
[CACHE] Filter notes by scope in pagedStream
...
This currently does not return a fixed number of notes per page. Fixing this is left as an exercise to the reader
2021-09-21 16:37:51 +01:00
14c173df7a
[CACHE][COMPONENT][Tag] Add generic Cache::pagedStream and use it for the tag stream. Note that it doesn't respect scope yet
2021-09-21 15:35:07 +01:00
6715a036e9
[CACHE] Add way to fetch limit,offset values from a list
2021-09-21 11:04:26 +01:00
ce80065775
[DB] Add mechanism for specifying limit and offset in dql query
2021-09-21 11:04:26 +01:00
91fd7d1cfa
[CONFIG][CORE] Fix bug in overriding default config
2021-09-21 11:04:14 +01:00
8bb6285522
[ENTITY][Note] A note may have no content
2021-09-20 17:06:21 +01:00
b7298eaa44
[ENTITY] ActorTag: use getter for tag name on toString
2021-09-20 17:05:50 +01:00
8fe8687c5b
[UTIL][HTML] Move to a unified array
2021-09-20 13:28:18 +01:00
e8f4563633
[UTIL][Formatting][COMPONENT][Link][Tag] Refactor code from formatting into Link and Tag, where appropriate. Drop 'perfect url regex' as the one used in v2 is better
2021-09-20 13:28:18 +01:00
556b8f8265
[ENTITY][NoteTag] Add 'canonical' field to tag
2021-09-20 13:27:27 +01:00
04174bc56d
[UTIL][UI] Change how plaintext notes are rendered to be split into paragraphs. Remove span around tags
2021-09-20 13:27:27 +01:00
51c7e10483
[UTIL][HTML] Allow specifying options: [raw => bool]
, whether to escape the provided inner HTML or not. Use with care
2021-09-20 13:27:21 +01:00
67d62cf37b
[TWIG] Remove kludge event TwigPopulateVars
2021-09-18 07:27:35 +01:00
fda998e335
[Avatar] We definitely don't need an event to retrieve avatar urls
2021-09-18 07:26:10 +01:00
2bd19fa087
[NOTE][Posting] Revert regressions introduced with c90efe2c52
...
Entity Note: It doesn't make sense to handle attachments on Note::create.
Attachments exist out of Notes, they are a thing on their own.
Furthermore, they aren't always handled the same, they most definitely
aren't always uploaded files.
FileQuota: It doesn't make sense to check if a file is greater than max
allowed upload size here. The plugin ensures a user is inside his
allowed quota, it's ignorant to anything else. Whether a file respect
max upload is a core thing that must be handled directly in the Posting
component. TODO: The configuration regarding user and monthly quota
must become FileQuotaPlugin settings and be removed from core.
c90efe2c52 - [UI] Add mechanism for rendering note contents in different formats. Implement plaintext rendering. Use rendered field for note content, rather than the content itself
2021-09-18 05:12:18 +01:00
941cbe6599
[Actor] Refactor GSActor into Actor
2021-09-18 05:12:17 +01:00
d6f31d102a
[CORE][ActivityStreamsTwo][ActivityPub] Set all routes
...
Allow global routes to act for every actor
Fix Favoured stream query
2021-09-18 05:12:15 +01:00
b177cb69e7
[HTML][SECURITY] Harden implmentation of HTML generation
2021-09-18 05:12:08 +01:00
8f0a3e4977
[UI] Add mechanism for rendering note contents in different formats. Implement plaintext rendering. Use rendered field for note content, rather than the content itself
2021-09-18 05:12:06 +01:00
f344ed376c
[ATTACHMENTS][Embed][UI] Allow plugins to provide a title for an attachment, if a note has none, implement such a mechanism in Embed and cache the result, since it is potentially costly
2021-09-18 05:12:06 +01:00
15a2a69274
[ROUTER] Add option is_system_path
, to allow specifying that a route, such as gsactor_view_nickname
should not be considered a system path, when checking for the collision of nicknames
2021-09-18 05:12:05 +01:00
e563c393f8
[ROUTER] Add mechanism for sorting the order in which core routes are loaded
2021-09-18 05:12:05 +01:00
e9d809d441
[Security][Exception] Security exception handling, login and register. TODO EmailNotFoundException and NicknameNotFoundException.
2021-09-15 14:48:06 +01:00
26af284353
[CONTROLLER][SECURITY] Registration feedback. The flashError works. However, Symfony's Exception error page is viewed upon trying to register.
2021-09-15 14:48:06 +01:00
365edbaff0
[ActivityStreamsTwo] Initial Actor support
...
Various bug fixes
2021-09-15 10:26:53 +01:00
1adde913c6
[PHPStan] Only run custom PHPStan extensions if environment vairable PHPSTAN_BOOT_KERNEL is defined (since it requires having the whole social setup available)
2021-09-14 13:13:45 +01:00
7c465bba5f
[NOTE] Add mimetype to notes
2021-09-14 13:13:45 +01:00
c69b28d894
[CORE] Fix Undefined array key 0
in DB::filterTableName
2021-09-14 13:13:45 +01:00
b74d944ae3
[TOOLS][PHPStan] Raise PHPStan level to 3 and fix new errors
2021-09-14 13:13:45 +01:00
f81bf4a257
[TOOLS][PHPStan] Add mechanism for initializing the whole application
2021-09-14 13:13:44 +01:00
ddb9702b1c
[TOOLS][PHPStan] Add support for deducing the correct entity type from a table name. Needs refactoring and can only run inside container, as it connects to the database itself
2021-09-14 13:13:44 +01:00
4e30e5aad9
[TOOLS] Fix all issues found by PHPStan level 2
2021-09-14 13:13:44 +01:00
61071a6821
[PLUGINS][Reply][Repeat][Favourite] Base template semantic rework. Reply, repeat and favourite respective classes are now assigned in their NoteHandlerPlugin.
2021-09-14 13:13:43 +01:00
ddd2ffe26a
[TWIG] Add extension to check if Firefox is being used
2021-09-14 13:13:43 +01:00
add8f4a52f
[TOOLS] Fix all errors found by PHPStan level 1
2021-09-14 13:13:42 +01:00
277a080d7c
[EXCEPTION] Add NotImplementedException
2021-09-14 13:13:42 +01:00
eb833b62e2
[TOOLS] Fix all level 0 errors found by PHPStan and move constant definition to bootstrap file
2021-09-14 13:13:42 +01:00
f65e2b90f2
[CORE] Fix use of Exception
class without import
2021-09-14 13:13:41 +01:00
cbbef90752
[UTIL][CONFIG] Ensure setConfig
uses a locals
key
2021-09-14 13:13:41 +01:00
4916c8cbda
[CONTROLLER][AdminPanel] Add missing Exception import
2021-09-14 13:13:41 +01:00
e8ae0b74e0
[CORE][Controller] Switch order for content negotiation: allow events to take precedence. Bring back default JSON response
2021-09-14 13:13:41 +01:00
cd89106fc0
[EXCEPTION][RedirectException] Add prevention for open redirects by default and ensure we can redirect to the same page
2021-09-14 13:13:40 +01:00
16cde6dfd7
[PLUGINS][Reply] Redirect back to previous URL on note reply. Move controller to own class
...
This should be safe against open redirects, as it doesn't allow redirecting to other domains
2021-09-14 13:13:40 +01:00
0a7fd9c460
[CORE][MODULES][NoteHandlerPlugin] Add missing import for Event
2021-09-14 13:13:40 +01:00
1d5fd1aefa
[CORE][Controller] Fix Controller::__invoke
so it actually passes on the route parameters to the controller method. Add Controller->string
, which gets a query parameter as a string value, or null if not set
2021-09-14 13:13:40 +01:00
330143e549
[ROUTER][DOCUMENTATION] Add Router::isAbsolute
, add documentation to Router::url
and `s/setRouter/serServices/
2021-09-14 13:13:39 +01:00
be27a10244
[EVENTS] Rename event RouteInFormat
to ControllerResponseInFormat
2021-09-14 13:13:39 +01:00
983e0303a5
[ROUTER] Sort routes so that the one with a smaller list of Accept types matches first
...
This requires a copy, but gets cached, so it's the ideal place to do it.
Note that only routes that match the incoming Accept match anyway, so the order between those with different accept types is not relevant
2021-09-14 13:13:39 +01:00
45734d882c
[CONFIG] Make it possible to write module configuration in a config.{php,yml,yaml,xml} file and set each value as properties in the module object
2021-09-14 13:13:38 +01:00
e4aa3ae968
[NOTE] Add route and controller
2021-09-14 13:13:37 +01:00
fd3b57dc24
[CORE][Controller] Make it possible for plugins to add different content-types to existing routes
2021-09-14 13:13:37 +01:00
626f50080b
[MODULES] Use snake_case for module config keys
2021-09-14 13:13:37 +01:00
033c4db914
[MODULES] Add function to defer module initialization and cleanup to plugin and component. Add example in Avatar component
...
Forward onInitializeModule to onInitializePlugin if the component is a plugin
2021-09-14 13:13:37 +01:00
bda839be7b
[MODULES] Add InitiializeModule and CleanupModule events, similar to v2
2021-09-14 13:13:37 +01:00
1ee8df1494
[DOCS][Developer] Elaborate on implementing and configuring a module
2021-09-14 13:13:37 +01:00
141f919ca7
[CONFIG][TESTS] Fix error found by AdminPanel test
2021-09-14 13:13:36 +01:00
c71a4b06ef
[CONFIG] Make it possible to write module configuration in a config.{php,yml,yaml,xml} file and set each value as properties in the module object
2021-09-14 13:13:36 +01:00
3587b8dc1d
[CONFIG] Refactor configuration loading
2021-09-14 13:13:36 +01:00
2fdd0b0820
[TESTS][DataFixtures] Use Temporary file instead of an ad-hoc solution to copy the upload files
2021-09-14 13:13:36 +01:00
2b457655ea
[CORE] Fix path configuration
2021-09-14 13:13:35 +01:00
e7b985a460
[FIXTURES] Catch any exception, we don't have VIPS-related only
2021-09-14 13:13:35 +01:00
f9079784c4
[ENTITY][AttachmentThumbnail] Improve the way EncoderPlugins participate in the thumbnail process
2021-09-14 13:13:35 +01:00
bc1fb007aa
[Core][GSFile] Improve the way EncoderPlugins participate in the file sanitization process
2021-09-14 13:13:34 +01:00
210f895e74
[ENTITY][Attachment] Respect rfc6838#section-4.2 mimetype length
2021-09-14 13:13:34 +01:00
2a3db65216
[CONTROLLER][Attachment] Some attachments may not have dimensions
2021-09-14 13:13:34 +01:00
26bf78360b
[ROUTER][UTIL] Allow specifying the Accept format for a route
2021-09-14 13:13:34 +01:00
811caaadf9
[MODULES][PLUGINS] Move noteActionHandle utility to NoteHandlerPlugin which plugins which handle actions on notes should extend
2021-09-14 13:13:34 +01:00
458b6d0009
[UI] Rename all forms to more specific names, to avoid form name collisions
2021-09-14 13:13:33 +01:00
6af1383e07
[UTIL][Form] Disallow using very generic form names, as they can collide with other forms in the same page
2021-09-14 13:13:33 +01:00
4cd3924cc1
[ATTACHMENTS][AttachmentThumbnail] Fix implementation of predictScalingValues and small fixes
2021-09-14 13:13:32 +01:00
2ccbbd53a6
[TESTS] Add code coverage annotations to entities
2021-09-14 13:13:32 +01:00
79215bc439
[Note] Fix scope check for group notes, move away from SQL, to DQL
2021-09-14 13:13:32 +01:00
e392a9c90c
[TESTS][DataFixtures] Add user, self follows, group member and group scope note
2021-09-14 13:13:32 +01:00
4b2a92d052
[UI][Attachment] Use Attachment methods to get the proper URL, rather than crafting it in a template
2021-09-14 13:13:32 +01:00
6799052ff5
[ATTACHMENTS] Ensure thumbnail dimensions are bounded and change way cropping is implemented
2021-09-14 13:13:32 +01:00
b50f11a040
[ENTITY][Link] self urls can't be considered a remote url
2021-09-14 13:13:31 +01:00
5c8677304c
[DOCS][Developer] Update storage documentation
2021-09-14 13:13:31 +01:00
e2e6c7a5bf
[TESTS] Hot-fix Security controller tests, broken with ongoing form rendering changes
2021-09-14 13:13:30 +01:00
44a581f0f6
[UTIL][FORM] Password form now shows the proper HTML class, and it's respective label.
2021-09-14 13:13:30 +01:00
87d7318de5
[CONTROLLER][SECURITY] Added class names. Help labels for each form element. Each form element now has a proper block prefix (the resulting HTML won't simply concatenate the form's name to the element's label).
2021-09-14 13:13:30 +01:00
ebee70621b
[FORM] Fix bug where options were passed in the data parameter
2021-09-14 13:13:30 +01:00
4f880eb761
[PLUGINS][ENTITY][Cover][ProfileColor] Clean up after interns and move entity defintions to be inside the corresponding plugin, rather than in core
2021-09-14 13:13:29 +01:00
2351e7c6d1
[CORE][GSFile] Use pathinfo rather than regular expressions and don't attempt to persist an already persisted entity
2021-09-14 13:13:28 +01:00
3843348c1b
[CONTROLLER][Attachment] Small refactor and add testing annotation
2021-09-14 13:13:28 +01:00
e2caf19b67
[TESTS] Remove copied upload test files, if upload failed
2021-09-14 13:13:28 +01:00
aef61e4c73
[TESTS] Add coverage ignore flags to trivial methods
2021-09-14 13:13:28 +01:00
fe86735b8b
[DB][DOCUMENTATION] Explain limit: 2 in findOneBy
2021-09-14 13:13:28 +01:00
c3db2f60d2
[UTIL][EXCEPTIONS] Introduce NotStoredLocallyException
2021-09-14 13:13:28 +01:00
6445a616a8
[ENTITY][Attachment] Raise mimetype max length to 64 characters and ensure we don't attempt to store more than that
2021-09-14 13:13:28 +01:00
d4d4f4e950
[TESTS] Cleanup attachment test data
2021-09-14 13:13:27 +01:00
6e6d1a946f
[TESTS] Remove MediaFileTest and move setup code to media data fixture
2021-09-14 13:13:27 +01:00
53f89ade85
[TESTS] Move Media fixtures to their own file, for organization
2021-09-14 13:13:27 +01:00
74d1874991
[DOCUMENTATION][Entity] Improve documentation on Entity::getWithPK, explaining the ways it can be used
2021-09-14 13:13:27 +01:00
060a5abef1
[ENTITY][Link] Sometimes URLs don't work, handle that
2021-09-14 13:13:27 +01:00
f690bc06ae
[ATTACHMENT] Some attachments don't have thumbnails and that's okay
2021-09-14 13:13:27 +01:00
b4a03b814f
[CORE][GSFile] ensureFilenameWithProperExtension: extension isn't an I/O param
2021-09-14 13:13:26 +01:00
728f8d8fb8
[ENTITY][Note] Add getter for note links
2021-09-14 13:13:26 +01:00
9e4cac0123
[ENTITY] Refactor RemoteURL entities to Link
...
RemoteURL was being an awfully confusing term.
2021-09-14 13:13:26 +01:00
968e3431e1
[Attachment] Sometimes we can't provide download of original file
2021-09-14 13:13:26 +01:00
4cc4523632
[Posting] Re-add original file to attachment on upload, if it was previously removed
2021-09-14 13:13:26 +01:00
d076781c74
[AttachmentToNote][Attachment] Add title getter to Attachment
2021-09-14 13:13:26 +01:00
bac18715c5
[StoreRemoteMedia] Implement the first version of it in v3
2021-09-14 13:13:25 +01:00
63cbf4052f
[UTIL] Common::config wasn't a proper port from v2, it has to accept one argument only as well
2021-09-14 13:13:25 +01:00
33cc9386d2
[RemoteURLToAttachment] Fix primary key, relation is: One Attachment Has Many URLs, One URL Has One Attachment
2021-09-14 13:13:25 +01:00
78c5c4b084
[Attachment] Allow to delete the associated file
2021-09-14 13:13:25 +01:00
508f1f8796
[MODULES] Add module configuration
2021-09-14 13:13:25 +01:00
de8a2f579c
[CORE][Event] Fix bug on handler Log
2021-09-14 13:13:25 +01:00
4ecdeac6a3
[CORE][Entity] Compare with object properties when creating/updating, instead of class
2021-09-14 13:13:25 +01:00
75f70f8182
[ENTITY][Posting] Remove GSActorToRemoteURL, Fix URL database store
2021-09-14 13:13:25 +01:00
f5175cc59d
[ATTACHMENTS] Always store in the same location
2021-09-14 13:13:24 +01:00
3f61537140
[ENTITY] Split Attachment in various new entities
...
Remove Attachment Scope
Fixed some minor bugs
Scope will be implemented later in v3. It doesn't make sense to have
the scope handling being per attachment. Different actors can post
the same attachment with different scopes. The attachment controller
will assume the highest level of scope applied to the attachment and
the rest will be handled at the note level.
Motivation:
* Remove title from attachment, as it's part of the relation between attachment and note.
* Remove actor from attachment, many actors may publish the same attachment.
* Remove is_local from attachment, as it's part of the relation between attachment and note.
* Remove remote_url from attachment, different urls can return the same attachment.
Addition:
* Attachment now has a lives attribute, it's a reference counter with a nicer name
* GSActorToAttachment
* GSActorToRemoteURL
* RemoteURL
* RemoteURLToNote
* RemoteURLToAttachment
* AttachmentToNote now has a title attribute
2021-09-14 13:13:24 +01:00
39006fb6b5
[DB][Attachments] Use count function rathar than fetch and count, rename to refCount, rather than countDepencies
2021-09-14 13:13:24 +01:00
809bf00aa9
[TemporaryFile][TESTS] Throw on attempt to write to null resource and fix tests
2021-09-14 13:13:24 +01:00
6728dd40b0
[ENTITY] Add JsonSerializable interface to Entity base class and implement it for the Note class
2021-09-14 13:13:24 +01:00
2851b899b8
[TESTS] Add test annotations to core classes
2021-09-14 13:13:23 +01:00
21a5bbe639
[CORE][Controller] Fix JSON response and add test annotations
2021-09-14 13:13:23 +01:00
061a85d6b3
[EVENTS] Change FormatNoteList do separate in and out arguments
...
This is necessary due to some weird problem which I wasn't able to figure out (but which doesn't matter)
that somehow causes the event to be called twice during testing, and thus the function was exploding
2021-09-14 13:13:23 +01:00
b5de80303a
[TEST] Raise test coverage for UserPanel to 100%
2021-09-14 13:13:23 +01:00
480665afc8
[CONTROLLER][UserPanel] Finish implementation of ::notifications so it actually saves the values in the database
2021-09-14 13:13:23 +01:00
cdf3426567
[CONTROLLR][UserPanel][PLUGINS] Add submit button to notification settings for each transport
2021-09-14 13:13:23 +01:00
afbcb179b2
[CONTROLLER][AdminPanel] Further ensure form validity
2021-09-14 13:13:23 +01:00
38a331220f
[CORE][Log] Add Log::unexpected_exception utility which logs and throws a ServerException
2021-09-14 13:13:23 +01:00
085e880631
[CORE][Entity] Fix implementation of createOrUpdate so it doesn't throw NotFoundException if trying to create an object
...
This was previously done because we wanted to notify the callee that
and entity existed but not with the provided contents. With the change
of return value, with a bool $is_update, this is no longer a problem.
2021-09-14 13:13:22 +01:00
1b623a85ae
[UTIL][FormFields] Move FormFields class to Util\Form namespace
2021-09-14 13:13:22 +01:00
1647c5391f
[Favourite][TWIG][CSS] Favourite now works.
2021-09-14 13:13:22 +01:00
21362d1e4d
[ATTACHMENTS] Add dependencies counter
2021-09-14 13:13:21 +01:00
3334aca7b9
[Avatar] Move entity from core to component
2021-09-14 13:13:20 +01:00
fb6aa78ae8
[CORE][GSFile] Allow storing files under /file
2021-09-14 13:13:20 +01:00
e688bf8aed
[TESTS] Ignore coverage of ResetPasswordRequest, as it uses mailing functionality. We may want to introduce this test in the future
2021-09-14 13:13:20 +01:00
9ad2cb5e66
[UTIL][FormFields] Allow specifying whether a password is required and provide placeholder text
2021-09-14 13:13:20 +01:00
5aedf64e5b
[ROUTES] Remove individual settings pages, as they got merged
2021-09-14 13:13:20 +01:00
27f2fbdade
[ENTITY] Refactor LocalUser::changePassword for easier use
2021-09-14 13:13:20 +01:00
19318b3163
[UTIL][EXCEPTION] Add AuthenticationException, representing an auth error, status code 401 unauthorized
2021-09-14 13:13:20 +01:00
a1592656e0
[TESTS] Change format of data fixtures to allow creating more users
2021-09-14 13:13:20 +01:00
2dd3511149
[CORE][DB] Specify desired case in array_change_case, for clarity
2021-09-14 13:13:19 +01:00
0ae67d96ea
[TESTS] Raise test coverage for AdminPanel to 100%
2021-09-14 13:13:19 +01:00
b77e35ef09
[SECURITY] Do not require email when in development
2021-09-14 13:13:19 +01:00
fe7c2b5115
[TESTS] Raise test coverage for AdminPanel controller to 100%
2021-09-14 13:13:19 +01:00
e0a0df502e
[TESTS] Raise test coverage for Attachment controller to 100%
2021-09-14 13:13:19 +01:00