Commit Graph

3068 Commits

Author SHA1 Message Date
Franz Liedke
0e5f334a0b
Locale: Don't resolve manager just to configure it
Refs #1578.
2018-12-19 22:07:31 +01:00
Franz Liedke
e4514d8413
Shorten registration of routes 2018-12-19 21:57:59 +01:00
Franz Liedke
1080d25561
Frontends: Populate default routes only when they are resolved 2018-12-19 21:55:58 +01:00
Franz Liedke
ba594de13a
Make site extenders run after extensions
Fixes #1708.
2018-12-19 21:30:29 +01:00
Daniël Klabbers
209d13affd add 7.3 to travis (#1710) 2018-12-19 18:09:36 +01:00
Daniel Klabbers
671fdec8d0 fixes #1695, post comment count is incorrectly calculated based on all posts, including events 2018-12-19 15:07:32 +01:00
Daniel Klabbers
9eca9192ca fixes a notice due to the forum variable not being defined before compacting 2018-12-19 11:40:48 +01:00
Franz Liedke
3468bdf511
Run local extenders before booting service providers
We still need to discuss the priority of local extenders vs. those
from enabled extensions, but let's first fix the actual bug.

Refs #1708.
2018-12-18 11:16:57 +01:00
Franz Liedke
54503d2c29
API: Populate default routes only when they are resolved
Refs #1708.
2018-12-18 10:33:01 +01:00
Franz Liedke
565131e2a7
Allow passing strings (names of invokable classes) to Formatter extender
In preparation for fixing #1703.
2018-12-15 12:05:17 +01:00
Toby Zerner
f0da3cf304
Remove obsolete binding 2018-12-14 11:28:11 +10:30
Franz Liedke
6acc91577d
Apply fixes from StyleCI (#1701)
[ci skip] [skip ci]
2018-12-14 01:48:19 +01:00
Franz Liedke
3e0cd3a21f
Use class constant to get qualified class names 2018-12-14 01:47:54 +01:00
Franz Liedke
5c9fa4c62d
Get rid of docblocks that don't add information 2018-12-13 23:08:49 +01:00
Franz Liedke
4b00f7996b
Early returns 2018-12-13 23:06:59 +01:00
Kirill
b58380e224 Fix incorrect docs link (#1699) 2018-12-13 20:19:13 +01:00
Franz Liedke
b0e996e7ff
Merge pull request #1697 from flarum/fl/1578-speed-up-extenders
Do not resolve services in extenders
2018-12-13 10:33:00 +01:00
Franz Liedke
b41d9fb0e7
Inject dependencies when firing events, not before
The event subscriber approach means that dependencies have to be
injected (and thus instantiated, along with all *their* dependencies) at
the time of registering event listeners - even when events are never
fired within a request's lifecycle.

This is unnecessary and causes more classes than necessary to be loaded.

In this case, we can explicitly register event listeners that will
resolve their dependencies when the event is fired, not before.

Refs #1578.
2018-12-13 02:01:50 +01:00
Franz Liedke
ed02eed88f
Do not resolve services when extending them
Refs #1578.
2018-12-13 01:58:54 +01:00
David Sevilla Martín
c761802900 Fix DELETE /api/extensions/* returning 500 (#1580)
* Use extension string as parameter for ::disable & ::uninstall

* Remove repeated 'ExtensionManager::disable' call

* Fix StyleCI
2018-12-13 00:16:03 +01:00
Arda Çebi
16eb1fa63b Profile group badge overlapping fix (#1506) 2018-12-12 22:24:30 +01:00
Franz Liedke
0ceb8d64df
Update changelog 2018-12-10 22:52:50 +01:00
Franz Liedke
9712eccb03
Add an issue template for security vulnerabilities 2018-12-10 22:43:03 +01:00
David Sevilla Martín
9684fbc4da Add 'hasPermission' helper to Group (#1688)
* Add Group@hasPermission helper

* Improve performance of method
2018-12-10 22:32:21 +01:00
Franz Liedke
67f9375d47
Fix incorrect column name for registration token
Oversight from the database renamings, I suppose.

Fixes #1691.
2018-12-09 23:17:04 +01:00
Toby Zerner
0d16fac001 Performance: Actually make use of the translator cache
We had added a `storage/locale` directory to our skeleton, but we had
forgotten to hook it up with the translator. Enabling caching saves
parsing that locale YAML files on every pageload which should be good
for performance.

The locale cache will be cleared whenever an extension that uses the
`Locales` or `LanguagePack` extenders is enabled/disabled. If debug
mode is ON, then the caching mechanism will automatically check if any
of the loaded YAML files are dirty and update accordingly.
2018-12-07 09:38:08 +10:30
Toby Zerner
a8f5ca8d97 Add another commit 2018-12-07 09:13:44 +10:30
Franz Liedke
bbe62f400f
Release version 0.1.0-beta.8.1 2018-12-06 00:47:38 +01:00
Franz Liedke
fc5977f86f
Do not create tables as InnoDB automatically, rely on connection default
As argued in #1675, this makes us slightly less reliant on MySQL.
2018-12-06 00:34:43 +01:00
Toby Zerner
796b57753d Don't output empty html tag attributes
From https://discuss.flarum.org/d/17817-meta-description-is-empty/8
ref #1677
2018-12-04 09:47:49 +10:30
Toby Zerner
88e43cc694 Fix empty meta description tag. Fixes #1677 2018-12-04 09:28:24 +10:30
Toby Zerner
6370f7ecff Set the default engine in the installer
The installer doesn't use DatabaseServiceProvider, so we need to set
the default engine in the config here too.

Fixes #1675
2018-12-04 09:12:19 +10:30
Toby Zerner
d9d7027ed0 Fix oopsie in fb6b51b1cf 2018-12-04 08:54:33 +10:30
flarum-bot
1106a2e3a3 Bundled output for commit b7f666525c [skip ci] 2018-12-02 22:26:12 +00:00
Toby Zerner
b7f666525c Update changelog 2018-12-03 08:51:27 +10:30
Toby Zerner
40dc6ac604 Fix discussion list scroll position not being maintained when hero is not visible 2018-12-03 08:50:54 +10:30
Toby Zerner
15e1a154e5 Add changelog 2018-12-02 08:08:44 +10:30
Franz Liedke
57d5846b64
Migrations: Fix dropping foreign keys
Passing an array to dropForeign does not mean dropping multiple indices,
but rather dropping a key on multiple tables.

Passing a string means that this string will be interpreted as index
name, not as name of the indexed column. Passing an array with one
string is therefore correct, in order to benefit from automatic index
name generation.
2018-11-30 14:02:37 +01:00
Franz Liedke
fb6b51b1cf
Set InnoDB for DB connection and new tables
Refs #1661.
2018-11-29 23:21:58 +01:00
Franz Liedke
57f73c9638
Installer: Fix invalid join time of admin user
Fixes #1664.
2018-11-29 22:56:56 +01:00
Franz Liedke
7705a2b7d7
Fix search with database prefix
wrap() only adds a table prefix when referencing a column with a table
name (such as `foo.bar`) - when only a single identifier is provided, it
is assumed to be a column name, which does not need a prefix.

Fixes #1659.
2018-11-29 22:50:32 +01:00
Franz Liedke
f591585d02
Fix live output in ResetCommand
This was forgotten in 9e487b4.

Fixes #1663.
2018-11-29 22:04:01 +01:00
Franz Liedke
45afc33eb0
Fix code style and doc block 2018-11-29 21:31:12 +01:00
Daniël Klabbers
213fd62be3 Up the version (#1582) 2018-11-29 00:34:49 +01:00
Franz Liedke
66607a5674
Always invalidate all user email tokens
Reported by B. Dhiyaneshwaran of Geek Freak.
2018-11-29 00:33:42 +01:00
Toby Zerner
546b4f01ac
Merge pull request #1656 from flarum/tz/fix-index-names
Fix index names in migrations
2018-11-27 22:32:17 +10:30
Toby Zerner
96e282458b Fix index names in migrations
This can be reverted when we upgrade to Laravel 5.7.
2018-11-27 12:19:13 +10:30
David Sevilla Martín
24ff8899a0
Throw FileNotFoundException when FileSource path does not exist
Closes #1649.
2018-11-22 23:40:38 +01:00
David Sevilla Martín
1b32c7cc51
Fix frontend extender using old container & wrong class 2018-11-22 21:17:32 +01:00
Franz Liedke
6c2a4a5ff7
Remove obsolete property accessor in User model
The locale field does not exist, and the accessor code was broken.

Closes #1653.
2018-11-22 21:12:25 +01:00