Commit Graph

3322 Commits

Author SHA1 Message Date
Franz Liedke
4eaf9ae23f New extender for error handling (#1970)
This extender implements several methods for extending the new error
handling stack implemented in #1843.

Most use-cases should be covered, but I expect some challenges for more
complex setups. We can tackle those once they come up, though. Basic
use-cases should be covered.

Fixes #1781.
2020-02-04 22:59:06 +01:00
flarum-bot
4d80700e97 Bundled output for commit 8877bf97c4 [skip ci] 2020-02-04 22:59:06 +01:00
Franz Liedke
8ad95a4dfb Clarify the use-case of the JS slug helper 2020-02-04 22:59:06 +01:00
Franz Liedke
03faaaedef Use Laravel's slugger for basic transliteration
This is better than the current system, as it adds transliteration rules
for special characters, rather than just throwing all of them away.

For languages that cannot be transliterated to ASCII in a reasonable
manner, more possible improvements are outlined in #194.
2020-02-04 22:59:06 +01:00
flarum-bot
5c3a0e3e6e Bundled output for commit 02ceed4fed [skip ci] 2020-02-04 22:59:06 +01:00
Clark Winkelmann
588f7498e1 Fix the "reply posted" alert empty body 2020-02-04 22:59:06 +01:00
Franz Liedke
8d1240559b Remove unnecessary use statement 2020-02-04 22:59:06 +01:00
ozzzzzzzam
7ad8eb7544 Remove forum title from confirmation email subject (#1613)
The forum title is already used as the display name for the sender email address, so having it in the subject is just a duplication and waste of space.
2020-02-04 22:59:06 +01:00
Matthew Kilgore
ebd2c69c8d Additional functionality for Middleware extender
Implements the remove, insertBefore, insertAfter and replace
functionality for middlewares.

The IoC container now holds one array of middleware (bindings) per
frontend stack - the extender operates on that array, before it is
wrapped in a middleware "pipe".

Fixes #1957, closes #1971.
2020-02-04 22:59:06 +01:00
flarum-bot
637ae1624c Bundled output for commit 02899d4f68 [skip ci] 2020-02-04 22:59:06 +01:00
David Sevilla Martín
0c9bcba3a6 Add Content for User page, preload user & throw 404 accordingly (#1901) 2020-02-04 22:59:06 +01:00
Franz Liedke
5b3acfc0d9 Convert another test
Test the request, not a controller (implementation detail). This also
focuses on the observable behavior instead of hacking our way into the
middleware pipeline in order to observe internal behavior.

The authenticated user is now determined by looking at the API response
to compare permissions and (non-)existing JSON keys.
2020-02-04 22:59:06 +01:00
David Sevilla Martín
7adfb5bd7e Initial template for Stale bot configuration (#1841) 2020-02-04 22:59:06 +01:00
Julian Berger
6b916065e9 Get translations from fallback catalogues (#1961) 2020-02-04 22:59:06 +01:00
Franz Liedke
f99f48b155 Add backwards compatibility layer for mail drivers
Support the old format (a simple list of available fields), in addition
to the new format (a map from field names to their types + metadata).

This will be removed after beta.12 is released.
2020-02-04 22:59:06 +01:00
Franz Liedke
d2c345c834 Document changes in mail driver interface 2020-02-04 22:59:06 +01:00
flarum-bot
966a093911 Bundled output for commit 4c89e2eb77 [skip ci] 2020-02-04 22:59:06 +01:00
Vladimir Vinogradov
0560238945 Add Mailgun region setting
Fixes #1834.
2020-02-04 22:59:05 +01:00
Franz Liedke
63801484fa Ensure page parameters are always integers 2020-02-04 22:59:05 +01:00
Matt Kilgore
f8d92edc9a Change Zend namespace to Laminas (#1963)
Also ensure backwards compatibility for extensions that use the Zend framework but don't explicitly require it.
2020-02-04 22:59:05 +01:00
Daniël Klabbers
e1dbfa7d68 Update LICENSE 2020-02-04 22:59:05 +01:00
Matt Kilgore
ef7623e4ff Middleware extender (#1952) 2020-02-04 22:59:05 +01:00
flarum-bot
d7fd076220 Bundled output for commit c1878fe29b [skip ci] 2020-02-04 22:59:05 +01:00
Franz Liedke
30a2421749 Update Webpack 2020-02-04 22:59:05 +01:00
Franz Liedke
1bf6e79b32 Catch more exceptions during boot process
This extends our boot exception handling block to also catch and format
all exceptions that could be thrown while building our request handler,
i.e. the middleware stack handling requests.

The only exceptions that would now not be handled in this way could be
raised by Zend's `RequestHandlerRunner` and its delegates, which we
should be able to rely on.

Exceptions on request execution will be handled by the error handler in
the middleware stack.

Fixes #1607.
2020-02-04 22:59:05 +01:00
w-4
8aaa39bd4e Fix update page with custom base path (#1947)
Calling UpdateHandler causes RouteNotFoundException when basepath is not /.
2020-02-04 22:59:05 +01:00
Franz Liedke
b1e11830d1 Link to security policy from README 2020-02-04 22:59:05 +01:00
Franz Liedke
3375f283eb FUNDING.yml does not inherit 2020-02-04 22:59:05 +01:00
Franz Liedke
df4c193ab7 Add a custom FUNDING.yml file for this repository
Let's hope GitHub inherits the lines from our default community health
files at https://github.com/flarum/.github.
2020-02-04 22:59:05 +01:00
Daniël Klabbers
5a8326f442 Update CHANGELOG.md 2020-02-04 22:59:05 +01:00
Daniel Klabbers
d8dd870efe releasing beta 11.1 2020-02-04 22:59:05 +01:00
Franz Liedke
60572b93fb Fix implementations of settings repo interface 2020-02-04 22:59:05 +01:00
Daniel Klabbers
810bfdc28f Revert "7.4 release, forcing tests to work with them"
This reverts commit da5628d125.
2020-02-04 22:59:05 +01:00
Daniel Klabbers
9c4a24b258 7.4 release, forcing tests to work with them 2020-02-04 22:59:05 +01:00
David Sevilla Martín
18462c079f Update Application version string to beta 11 2020-02-04 22:59:05 +01:00
Franz Liedke
10d6e653cb Apply fixes from StyleCI
[ci skip] [skip ci]
2020-02-04 22:59:05 +01:00
Franz Liedke
4e1f753f59 Update copyright claims in LICENSE 2020-02-04 22:59:04 +01:00
Daniel Klabbers
3c2dd23765 preparing the changelog for beta 11, part 2 2020-02-04 22:59:04 +01:00
Daniel Klabbers
aebc23cba2 preparing the changelog for beta 11 2020-02-04 22:59:04 +01:00
Clark Winkelmann
f6d03771cb Fix tests to include expectation count and run user saving events 2020-02-04 22:59:04 +01:00
Clark Winkelmann
54be9573ac Add unit test for AvatarUploader 2020-02-04 22:59:04 +01:00
Clark Winkelmann
bf46ea3840 Fix avatar files not being deleted. Fixes #1918 2020-02-04 22:59:04 +01:00
flarum-bot
bab49650e6 Bundled output for commit 17c86b82bf [skip ci] 2020-02-04 22:59:04 +01:00
w-4
a789c6b4e9 history back function fix
it shouldn't check for canGoBack again after the array pop()
2020-02-04 22:59:04 +01:00
Daniel Klabbers
3b3459ad3d incorrect ability used, drop prefix discussion. 2020-02-04 22:59:04 +01:00
Daniel Klabbers
223f4d93d4 test only on the hidePosts policy ability 2020-02-04 22:59:04 +01:00
Daniel Klabbers
5d1fe9b815 resume chain in query builder 2020-02-04 22:59:04 +01:00
Daniël Klabbers
521834f5da [review] using orWhere to allow any where to follow in extensions 2020-02-04 22:59:04 +01:00
Daniël Klabbers
622e2a6644 fixes #1827
- set default statement to block access
- added tests to confirm all scenarios work as intended
2020-02-04 22:59:04 +01:00
Franz Liedke
c5e38a5b1f Automatically set up Mockery for unit tests
- Use provided PhpUnit listener to enforce verification of expectations.
- Include Mockery's trait to auto-close Mockery after each test.
2020-02-04 22:59:04 +01:00