72 Commits

Author SHA1 Message Date
HDVinnie
adb91f6de5 Merge pull request #4501 from Roardom/fix-staff-forum-notifications
(Fix) Send staff forum notificaton to all permitted to the forum
2025-03-04 21:31:03 -05:00
Jay Sizzla
aa8cefe803 Use shouldSend for NewPost notifications 2025-02-27 13:08:43 +00:00
Roardom
5786aa240d fix: send staff forum notificaton to all permitted to the forum
Instead of hard coding it to the is_modo perm. This became an issue when the is_torrent_modo flag was added.
2025-02-25 12:59:41 +00:00
Roardom
868ad35aa4 refactor: swap magic RedirectResponse withX('Y') to with('X', 'Y')
Allows ctrl+clicking to access the underlying function unlike the previous magic implementation. Probably also negligibly faster.

Swapped all instances of `>withSuccess(` -> `>with('success', `, `>withWarning(` -> `>with('warning', `, and `>withInfo(` -> `>with('info', ` with ide's find and replace.
2025-01-21 16:05:11 +00:00
HDVinnie
98e5cbf518 fix: Call to a member function isNot() on null
- the post delete function needs to be updated. issue is if the first post of topic is deleted then then the $topic->first_post_user_id is no longer valid
2025-01-02 15:19:49 -05:00
Roardom
34a443608e fix: topic starters not receiving notifications
regression from 7490a7a
2024-08-28 16:57:13 +00:00
Roardom
64a60089d9 refactor: treat sprintf as native function
This breaks the pint CI currently. This is probably due to the next version of php (8.4) adding opcache optimizations to sprintf and our config requiring pre-slashing native functions.
2024-08-09 21:08:26 +00:00
Roardom
93e748a3e5 fix: tagging users in posts
It looks like the intention of this code was to omit the author of the post from the notifications, but instead it was comparing the author's id to itself, thereby always being false and no notifications ever being sent.
2024-05-25 12:51:31 +00:00
Roardom
b86475a732 add: strict types to all files 2024-05-23 13:58:29 +00:00
Roardom
6e5b3d9e3b refactor: use scope for forum authorization 2024-02-25 10:23:56 +00:00
Roardom
7490a7a39e refactor: forum notification triggers 2024-02-13 22:50:57 +00:00
Roardom
686f1560ca update: separate forum categories into their own model 2024-02-12 07:39:52 +00:00
Roardom
f30dec4a0c update: remove show_forum permission
This permission is used the same as the `read_topic` permission.
2024-02-10 19:50:05 +00:00
Roardom
834d438281 update: normalize forums a little more
We already make most of these queries anyways, and we'll need these foriegn keys when implementing future forum features like 'catch up'.
2024-02-09 16:44:52 +00:00
Roardom
0ef7cc235a fix: phpstan level 7 controller errors 2024-01-07 17:13:20 +00:00
HDVinnie
3f03214e39 PHP Style Change (Laravel Pint CI) 2023-11-07 23:54:38 +00:00
HDVinnie
b3f0386149 cleanup: pt.1 2023-10-12 22:30:52 -04:00
HDVinnie
88d114c526 PHP Style Change (Laravel Pint CI) 2023-08-30 09:39:04 +00:00
Roardom
9ba5c7e7c3 update: lazily compute forum post permalink page number 2023-07-15 23:24:26 +00:00
Roardom
9d4789ba91 refactor: require whitespace before statements 2023-07-07 00:27:13 +00:00
Roardom
57e531f37e fix: only update the latest topic of the deleted post's forum
Also set `$isTopicDeleted` to false by default.
2023-05-11 20:32:27 +00:00
HDVinnie
fb35e4039d update: forums
Co-Authored-By: Roardom <78790963+Roardom@users.noreply.github.com>
2023-05-07 22:21:18 -04:00
Roardom
8824abd9d5 update: forums 2023-05-08 01:30:43 +00:00
HDVinnie
2e4d669abf Merge pull request #2688 from Roardom/fix-achievement-unlock
(Fix) Achievement unlock
2023-04-12 04:24:15 -04:00
Roardom
a0429ca442 fix: achievement unlock
The unlock() function only takes a single argument
2023-04-12 03:19:22 +00:00
Roardom
94efa52b02 fix: wrong topic field 2023-04-12 02:57:26 +00:00
Roardom
f3297917bb update: use livewire for forums 2023-02-08 18:14:14 -06:00
HDVinnie
f4ebee885c update: lint 2023-02-03 22:23:00 -05:00
HDVinnie
3650900c97 update: lint
- not_operator_with_space to false
2023-02-03 16:01:29 -05:00
HDVinnie
472c820f99 update: UNIT3D linting
- github action updated with new ruleset in pint.json
- codebase linted with new ruleset
- contributors can now run `./vendor/bin/pint`
- action workflow will auto correct any lint issues upon commit/opened pull request
2023-02-02 08:02:34 -05:00
HDVinnie
35bfa41b97 refactor: user tagging
- simplify user tagging for posts and comments
2022-12-26 20:50:38 -05:00
HDVinnie
2ca429c4ce Revert "PSR12 Linting"
This reverts commit 7e65e1d589.
2022-09-11 19:51:58 -04:00
HDVinnie
7e65e1d589 PSR12 Linting 2022-09-11 23:50:41 +00:00
HDVinnie
594b7864d9 refactor: adopt new helpers in laravel 9 2022-03-06 17:20:05 -05:00
HDVinnie
bdd63aa816 update: controllers 2022-02-28 05:06:55 -05:00
HDVinnie
d3abd28925 update: type hints 2022-01-08 15:35:53 -05:00
HDVinnie
a2cdb5f5ff update: type hints 2022-01-08 14:37:50 -05:00
HDVinnie
77ec35bea5 chore: apply the laravel code style linter 2022-01-08 00:03:12 -05:00
HDVinnie
97394c062f chore: adopt type hints 2022-01-07 23:35:33 -05:00
alkl58
8bc19c4a37 PostController: German & French Translation 2021-12-14 19:58:02 +01:00
HDVinnie
3f0069dbeb Apply fixes from StyleCI 2021-10-26 17:06:47 +00:00
HDVinnie
8c96dae0de fix: forum/topic/post permissions
- this system to be cleaned up and refactored a bit
2021-10-26 13:06:26 -04:00
HDVinnie
2a53cea216 refactor: newline after statement 2021-09-28 12:49:46 -04:00
clandestine8
a737482e79 Apply fixes from StyleCI
[ci skip] [skip ci]
2021-09-06 23:26:02 +00:00
HDVinnie
321847e067 Apply fixes from StyleCI
[ci skip] [skip ci]
2021-05-16 02:41:53 +00:00
HDVinnie
3407075214 refactor: better php8 usage
- Change simple property init and assign to constructor promotion
- Remove unused variable in catch()
- Change docs types to union types, where possible
2021-05-15 22:41:28 -04:00
HDVinnie
467d31f10a refactor: constructor promotions 2020-12-17 23:25:50 -05:00
HDVinnie
0733269867 update: phpdoc blocks 2020-07-22 16:57:13 -04:00
HDVinnie
a975116218 refactor: preslash simple functions
- Add pre-slash to short named functions to improve performance by almost 30%
-  @see https://stackoverflow.com/questions/55419673/php7-adding-a-slash-to-all-standard-php-functions-php-cs-fixer-rule
2020-07-22 15:09:37 -04:00
HDVinnie
e7ccde0190 refactor: rename property to match type 2020-07-22 14:50:41 -04:00