Alexander Ebert [Sat, 29 Oct 2022 14:12:07 +0000 (16:12 +0200)]
Add `reflect-metadata`
Alexander Ebert [Sat, 29 Oct 2022 12:17:15 +0000 (14:17 +0200)]
Add decorators to implicitly bind to DOM elements
mutec [Thu, 6 Oct 2022 20:56:44 +0000 (22:56 +0200)]
Add return type to AbstractFormFieldDecorator::getAttribute()
see
a95b68e5bc004c04909f79c64922bbf486535bb2
Closes #5032
Tim Düsterhus [Mon, 31 Oct 2022 11:30:38 +0000 (12:30 +0100)]
Merge branch '5.5'
Sascha Greuel [Mon, 31 Oct 2022 11:04:20 +0000 (12:04 +0100)]
Update outdated links within phrases (#5096)
see #5095
see https://www.woltlab.com/community/thread/297811-neuer-twitter-link-registrierung/
Tim Düsterhus [Mon, 31 Oct 2022 09:50:17 +0000 (10:50 +0100)]
Merge remote-tracking branch 'origin/master'
Tim Düsterhus [Mon, 31 Oct 2022 09:49:46 +0000 (10:49 +0100)]
Merge branch '5.5'
Sascha Greuel [Mon, 31 Oct 2022 09:38:44 +0000 (10:38 +0100)]
Update Twitter Developer link (#5095)
See https://www.woltlab.com/community/thread/297811-neuer-twitter-link-registrierung/
Niklas [Mon, 31 Oct 2022 08:09:02 +0000 (09:09 +0100)]
Fix typo in PHPDoc in `ValueFormFieldDependency` (#5089)
Tim Düsterhus [Fri, 28 Oct 2022 14:41:04 +0000 (16:41 +0200)]
Add explicit `void` return type to UserLoginCancelLostPasswordListener::__invoke()
Tim Düsterhus [Fri, 28 Oct 2022 14:33:46 +0000 (16:33 +0200)]
Add return type to bootstrap closure
Tim Düsterhus [Fri, 28 Oct 2022 11:32:57 +0000 (13:32 +0200)]
Merge pull request #5084 from WoltLab/require-minversion
Require the `minversion` of a `<requiredpackage>` to be set
Tim Düsterhus [Fri, 28 Oct 2022 11:31:17 +0000 (13:31 +0200)]
Merge pull request #5086 from WoltLab/logging-aware-exception
Remove ILoggingAwareException
Tim Düsterhus [Fri, 28 Oct 2022 11:30:57 +0000 (13:30 +0200)]
Merge pull request #5085 from WoltLab/escapeString
Remove the global `escapeString()` function
Tim Düsterhus [Fri, 28 Oct 2022 10:54:57 +0000 (12:54 +0200)]
Remove ILoggingAwareException
See the deprecation commit
55343e879a9546d30539d7c746b2de22733469be for
reasoning.
Tim Düsterhus [Fri, 28 Oct 2022 10:46:40 +0000 (12:46 +0200)]
Remove the global `escapeString()` function
This function is trivially replaced if still used and the removal cleans up
core.functions.php a little further.
Tim Düsterhus [Fri, 28 Oct 2022 10:43:22 +0000 (12:43 +0200)]
Remove redundant PHPDoc type in DatabasePackageInstallationPlugin
Tim Düsterhus [Fri, 28 Oct 2022 10:38:49 +0000 (12:38 +0200)]
Require the `minversion` of a `<requiredpackage>` to be set
If “any version” is actually what is desired, a minversion of `0.0.0` or
similar can be specified, but more often than not a missing minversion is an
accident.
Tim Düsterhus [Fri, 28 Oct 2022 10:01:13 +0000 (12:01 +0200)]
Add proper types to BackgroundQueueHandler
Tim Düsterhus [Fri, 28 Oct 2022 09:58:23 +0000 (11:58 +0200)]
Use `->prepare()` instead of `->prepareStatement()` in BackgroundQueueHandler
Tim Düsterhus [Fri, 28 Oct 2022 09:57:30 +0000 (11:57 +0200)]
Mark BackgroundQueueHandler as final
Tim Düsterhus [Thu, 27 Oct 2022 11:43:48 +0000 (13:43 +0200)]
Add wcf1_language.locale to update_com.woltlab.wcf_6.0.php
see
c453132c800e1ad123439875332934c74674bc42
Tim Düsterhus [Fri, 28 Oct 2022 08:04:15 +0000 (10:04 +0200)]
Merge branch '5.5'
Tim Düsterhus [Fri, 28 Oct 2022 07:08:26 +0000 (09:08 +0200)]
Merge pull request #5083 from WoltLab/cryptoutil-performance
Improve performance of CryptoUtil::getValueFromSignedString()
Tim Düsterhus [Thu, 27 Oct 2022 15:29:42 +0000 (17:29 +0200)]
Fix CryptoUtil API misuse in SessionHandler
The previous version was not incorrect (we never sign a falsy string in
SessionHandler). However the return value should always be explicitly compared
to `null` to make verification of correctness easier.
Tim Düsterhus [Thu, 27 Oct 2022 15:25:33 +0000 (17:25 +0200)]
Stop using `CryptoUtil::validateSignedString()` in `SessionHandler`
Tim Düsterhus [Thu, 27 Oct 2022 15:23:09 +0000 (17:23 +0200)]
Deprecate CryptoUtil::validateSignedString()
Tim Düsterhus [Thu, 27 Oct 2022 15:13:27 +0000 (17:13 +0200)]
Improve performance of CryptoUtil::getValueFromSignedString()
Previously the method required to b64 decode the value twice, once for the
validation in `validateSignedString()` and once more to actually decode it.
This was fairly slow, due to the constant time encoder being used for decoding,
causing the b64 decoder to account for more almost 1% of time spent for simple
requests, now it's down to ~0.6% of the reduced total.
The change is safe, because there is no way for valid return value to be
confused with an invalid return value, due to entirely distinct types being
used (string vs null). Thus `validateSignedString()` can simply delegate to
`getValueFromSignedString()`.
Tim Düsterhus [Thu, 27 Oct 2022 12:48:06 +0000 (14:48 +0200)]
Merge pull request #5081 from WoltLab/avatar-maxSize
Remove the `user.profile.avatar.maxSize` userGroupOption
Tim Düsterhus [Thu, 27 Oct 2022 11:33:56 +0000 (13:33 +0200)]
Merge pull request #5082 from WoltLab/abstract-oauth-action
Require PSR-7 responses in AbstractOauth2Action
Tim Düsterhus [Thu, 27 Oct 2022 11:33:41 +0000 (13:33 +0200)]
Merge pull request #5080 from WoltLab/wcf-n
Unify ApplicationHandler::insertRealDatabaseTableNames() and Database::prepare()
Tim Düsterhus [Thu, 27 Oct 2022 10:11:32 +0000 (12:11 +0200)]
Return PSR-7 response in AbstractOauth2Action::initiate()
Also technically a small break if some code calls `->initiate()` manually and
expects it to `never` return due to the `exit;`. Any classes overriding
`initiate()` will notice due to the new return type of the previous commit, any
other manual uses are very unlikely and not how AbstractOauth2Action is
supposed to be used.
Tim Düsterhus [Thu, 27 Oct 2022 10:08:33 +0000 (12:08 +0200)]
Add `ResponseInterface` return types to AbstractOauth2Action
This will require an update in downstream users, unless they already migrated
returning `ResponseInterface` with 5.5, as done with the “bundled” providers.
Tim Düsterhus [Thu, 27 Oct 2022 09:13:25 +0000 (11:13 +0200)]
Remove the `user.profile.avatar.maxSize` userGroupOption
Resolves #4743
Tim Düsterhus [Thu, 27 Oct 2022 08:11:15 +0000 (10:11 +0200)]
Remove `!PACKAGE_ID` case from ApplicationHandler::insertRealDatabaseTableNames()
WCF_N can only be 1 during WCFSetup, as the field has been removed. Thus this
code path is dead.
Tim Düsterhus [Thu, 27 Oct 2022 08:10:05 +0000 (10:10 +0200)]
Delegate to ApplicationHandler::insertRealDatabaseTableNames() in Database::prepare()
Resolves #4641
Tim Düsterhus [Thu, 27 Oct 2022 07:56:11 +0000 (09:56 +0200)]
Use regex solution from Database::prepare() in ApplicationHandler::insertRealDatabaseTableNames()
This is both
- (a) a little more correct as it matches at word boundaries only, and
- (b) faster, likely due to less function calls and less full string scans
required.
Tim Düsterhus [Thu, 27 Oct 2022 07:48:51 +0000 (09:48 +0200)]
Add proper types to ApplicationHandler::insertRealDatabaseTableNames()
Tim Düsterhus [Wed, 26 Oct 2022 15:08:55 +0000 (17:08 +0200)]
Run `composer bump`
Tim Düsterhus [Wed, 26 Oct 2022 15:06:53 +0000 (17:06 +0200)]
Merge branch '5.5'
Tim Düsterhus [Wed, 26 Oct 2022 15:06:11 +0000 (17:06 +0200)]
Update `guzzlehttp/psr7` composer dependency
Tim Düsterhus [Wed, 26 Oct 2022 13:56:53 +0000 (15:56 +0200)]
Fix `copy` icon in WoltLabSuite/Core/Ui/Feed/Dialog
Tim Düsterhus [Wed, 26 Oct 2022 13:50:50 +0000 (15:50 +0200)]
Add `language` PIP to preliminary update instructions
Tim Düsterhus [Wed, 26 Oct 2022 13:17:29 +0000 (15:17 +0200)]
Update preliminary update instructions from 5.5
Tim Düsterhus [Wed, 26 Oct 2022 13:17:16 +0000 (15:17 +0200)]
Update fileDelete.xml
Tim Düsterhus [Wed, 26 Oct 2022 13:10:11 +0000 (15:10 +0200)]
Fix update_com.woltlab.wcf_6.0_checkSystemRequirements.php
Tim Düsterhus [Wed, 26 Oct 2022 12:42:13 +0000 (14:42 +0200)]
Check for `intl` in update_com.woltlab.wcf_6.0_checkSystemRequirements.php
Tim Düsterhus [Wed, 26 Oct 2022 12:30:35 +0000 (14:30 +0200)]
Add VisitTracker::prune()
Tim Düsterhus [Wed, 26 Oct 2022 12:28:11 +0000 (14:28 +0200)]
Use `->prepare()` instead of `->prepareStatement()` in VisitTracker
Tim Düsterhus [Wed, 26 Oct 2022 12:26:19 +0000 (14:26 +0200)]
Merge pull request #5078 from WoltLab/early-boot
Unify the early-boot logic
Tim Düsterhus [Wed, 26 Oct 2022 12:08:44 +0000 (14:08 +0200)]
Do not reference WCF_DIR during early boot
Instead use a path derived from `__DIR__`. This allows to require the composer
loader outside of `NO_IMPORTS`, reducing the amount of special-cased logic.
Tim Düsterhus [Wed, 26 Oct 2022 12:02:55 +0000 (14:02 +0200)]
Move the configuration of `zlib.output_compression` to early-boot
Now the full environment configuration is at the top of WCF.class.php.
Tim Düsterhus [Wed, 26 Oct 2022 12:01:16 +0000 (14:01 +0200)]
Move the exception ini configuration to early-boot
This is not well-placed in core.functions.php, because that does not run during
WCFSetup.
Tim Düsterhus [Wed, 26 Oct 2022 11:59:37 +0000 (13:59 +0200)]
Move the mbstring configuration into early boot
This no longer needs to be duplicated across WCF and WCFSetup.
Tim Düsterhus [Wed, 26 Oct 2022 11:56:48 +0000 (13:56 +0200)]
Merge pull request #5077 from WoltLab/abstract-integer-require-identifier
Make AbstractIntegerCondition::getIdentifier() abstract
Tim Düsterhus [Wed, 26 Oct 2022 10:36:48 +0000 (12:36 +0200)]
Merge pull request #5076 from WoltLab/template-empty-array-literal
Support empty-array literals in templates
Tim Düsterhus [Wed, 26 Oct 2022 10:35:14 +0000 (12:35 +0200)]
Merge pull request #5075 from WoltLab/event-listener-options
Soft-deprecate `<permissions>` and `<options>` in eventListener.xml
Tim Düsterhus [Wed, 26 Oct 2022 10:15:49 +0000 (12:15 +0200)]
Merge remote-tracking branch 'origin/master'
Tim Düsterhus [Wed, 26 Oct 2022 10:07:58 +0000 (12:07 +0200)]
Make AbstractIntegerCondition::getIdentifier() abstract
This forces the user to explicitly specify an identifier, instead of relying on
the empty default that will easily collide with other fields.
Resolves #4740
Tim Düsterhus [Wed, 26 Oct 2022 10:05:22 +0000 (12:05 +0200)]
Add return types to AbstractIntegerConditions
Tim Düsterhus [Wed, 26 Oct 2022 09:36:12 +0000 (11:36 +0200)]
Support empty-array literals in templates
This allows replacing: `{if $someArray|empty}` with `{if $someArray === []}`.
Tim Düsterhus [Tue, 25 Oct 2022 15:46:50 +0000 (17:46 +0200)]
Merge pull request #5073 from WoltLab/encode-json
Remove `StringUtil::encodeJSON()`
Tim Düsterhus [Tue, 25 Oct 2022 15:44:40 +0000 (17:44 +0200)]
Remove `<options>` and `<permissions>` from eventListener.xsd
see #4748
Tim Düsterhus [Tue, 25 Oct 2022 15:44:00 +0000 (17:44 +0200)]
Hide `<options>` and `<permissions>` from eventListener PIP GUI unless non-empty
see #4748
Tim Düsterhus [Tue, 25 Oct 2022 14:56:17 +0000 (16:56 +0200)]
Apply `formatNegative()` in `StringUtil::formatNumeric()`
Tim Düsterhus [Tue, 25 Oct 2022 14:51:05 +0000 (16:51 +0200)]
Remove `StringUtil::encodeJSON()`
The function is completely broken as indicated in the comment and the
replacement template modifier `|json` was backported roughly everywhere. There
is no need for this to still exist.
Tim Düsterhus [Tue, 25 Oct 2022 14:24:50 +0000 (16:24 +0200)]
Update composer dependencies
Tim Düsterhus [Tue, 25 Oct 2022 14:22:47 +0000 (16:22 +0200)]
Merge branch '5.5'
Tim Düsterhus [Tue, 25 Oct 2022 14:20:40 +0000 (16:20 +0200)]
Update `guzzlehttp/psr7` composer dependency
Tim Düsterhus [Tue, 25 Oct 2022 13:26:33 +0000 (15:26 +0200)]
Merge pull request #5072 from WoltLab/js-template-plural
Inline WoltLabSuite/Core/I18n/Plural in Template module
Tim Düsterhus [Tue, 25 Oct 2022 12:44:22 +0000 (14:44 +0200)]
Inline WoltLabSuite/Core/I18n/Plural in Template module
In
c0b2cbfb163d298bbfffa6f3824a287fd4e273a5 the vast majority of the Plural
module contents has already been removed in favor of Intl.PluralRules, only the
template functionality remained. This commit inlines the functionality into the
Template module to allow removing the module entirely.
The differences in Template.grammar.js are larger than expected, apparently
some kind of autoformatter was once applies to the file by accident. I have
verified with `git diff --word-diff` that the renaming of the function call was
the only real change in the file.
Tim Düsterhus [Tue, 25 Oct 2022 12:21:30 +0000 (14:21 +0200)]
Clean up WoltLabSuite/Core/Template/Compiler#compile()
Tim Düsterhus [Tue, 25 Oct 2022 12:20:50 +0000 (14:20 +0200)]
Merge pull request #5071 from WoltLab/js-numberutil
Deprecate WoltLabSuite/Core/NumberUtil
Tim Düsterhus [Tue, 25 Oct 2022 12:11:39 +0000 (14:11 +0200)]
Deprecate `WoltLabSuite/Core/NumberUtil`
Tim Düsterhus [Tue, 25 Oct 2022 12:07:02 +0000 (14:07 +0200)]
Remove NumberUtil dependency from `WoltLabSuite/Core/StringUtil`
Tim Düsterhus [Tue, 25 Oct 2022 12:02:27 +0000 (14:02 +0200)]
Merge pull request #5070 from WoltLab/js-template
Clean up JavaScript Templates
Tim Düsterhus [Tue, 25 Oct 2022 11:36:03 +0000 (13:36 +0200)]
Remove WCF.Template
While not officially deprecated, the module-based replacement
WoltLabSuite/Core/Template exists since a while. The implementation based on
naïve string replacement is also very questionable.
Tim Düsterhus [Tue, 25 Oct 2022 11:35:33 +0000 (13:35 +0200)]
Replace `WCF.Template` by `WoltLabSuite/Core/Template` in bbcodeAdd.tpl
Tim Düsterhus [Tue, 25 Oct 2022 11:00:08 +0000 (13:00 +0200)]
Completely remove `Core/Template.callbacks` property
Any attempt to access this resulted in an Error for a long time, it's time to
remove it completely.
Tim Düsterhus [Tue, 25 Oct 2022 10:38:57 +0000 (12:38 +0200)]
Add `null` default value to properties of TDecimalsDatabaseTableColumn and TLengthDatabaseTableColumn
see
3f13d793c2d163827df896effc1bb90b1fa4888f
Tim Düsterhus [Tue, 25 Oct 2022 10:15:07 +0000 (12:15 +0200)]
Unbreak WCFSetup
The WCF_UUID option is only available after WCFSetup and installation of
`com.woltlab.wcf` completed.
Alexander Ebert [Mon, 24 Oct 2022 16:41:03 +0000 (18:41 +0200)]
Update the visuals of the drop-down menus
Tim Düsterhus [Mon, 24 Oct 2022 14:49:35 +0000 (16:49 +0200)]
Merge pull request #5068 from HanashiDev/registryhandler-rev
Add proper types to RegistryHandler
Hanashi [Mon, 24 Oct 2022 14:36:56 +0000 (16:36 +0200)]
Replace `empty` in RegistryHandler if possible
Hanashi [Mon, 24 Oct 2022 14:34:31 +0000 (16:34 +0200)]
Replace `prepareStatement` with `prepare` in RegistryHandler
Hanashi [Mon, 24 Oct 2022 14:32:24 +0000 (16:32 +0200)]
Mark properties in `RegistryHandler` as `private`
Hanashi [Mon, 24 Oct 2022 14:31:34 +0000 (16:31 +0200)]
Add proper types to `RegistryHandler`
Hanashi [Mon, 24 Oct 2022 14:26:51 +0000 (16:26 +0200)]
Mark `RegistryHandler` as `final`
Tim Düsterhus [Mon, 24 Oct 2022 14:26:48 +0000 (16:26 +0200)]
Merge pull request #5056 from WoltLab/package-bootstrap
Add bootstrapping scripts
Tim Düsterhus [Mon, 24 Oct 2022 14:21:20 +0000 (16:21 +0200)]
Merge pull request #5067 from HanashiDev/formbuilder-missing-return-types
Add missing return types in FormBuilder
Hanashi [Mon, 24 Oct 2022 14:15:17 +0000 (16:15 +0200)]
Add missing return types on formbuilder fields
Tim Düsterhus [Mon, 24 Oct 2022 13:32:49 +0000 (15:32 +0200)]
Merge pull request #5066 from HanashiDev/php-ddl-rework
Add proper types to PHP-DDL-API
Hanashi [Mon, 24 Oct 2022 07:31:01 +0000 (09:31 +0200)]
Add return type `static` for `@return $this`
Hanashi [Sun, 23 Oct 2022 10:14:06 +0000 (12:14 +0200)]
Mark protected as private in final classes
Hanashi [Sat, 22 Oct 2022 09:28:07 +0000 (11:28 +0200)]
Add proper types to DatabaseTable
Hanashi [Sat, 22 Oct 2022 09:22:03 +0000 (11:22 +0200)]
Add proper type `mixed` to DatabaseTableColumn
Hanashi [Sat, 22 Oct 2022 08:51:00 +0000 (10:51 +0200)]
Add proper types to *DatabaseTableColumns
Hanashi [Sun, 23 Oct 2022 10:25:27 +0000 (12:25 +0200)]
Mark `protected` as `private` in `DatabaseTableChangeProcessor`
Hanashi [Sat, 22 Oct 2022 13:17:57 +0000 (15:17 +0200)]
Replace empty function in DatabaseTable and DatabaseTableChangeProcessor
Tim Düsterhus [Mon, 24 Oct 2022 08:05:42 +0000 (10:05 +0200)]
Merge branch '5.5'