Commit Graph

11157 Commits

Author SHA1 Message Date
Earlopain
4ede4cefb3
[Docker] Improve file permissions
Volumes get created on the host as the user that docker is running as (root, most likely)
This is annoying, and creates issues when running the image as a non-root user
2024-01-14 16:30:51 +01:00
Earlopain
8e94b9776e
[Discord] Generalize reports a bit more 2024-01-14 13:39:57 +01:00
Cinder
49cf270d90
[Posts] Tweak the janitor toolbar (#589)
* [Posts] Tweak the janitor toolbar

* [Posts] Remove the duplicate count from the modbar

* [Posts] More tweaks to the janitor toolbar

Based on the input from the janitors themselves.

* Linting
2024-01-14 12:38:02 +01:00
Earlopain
1fed677a45
[Tickets] Make response mandatory 2024-01-14 12:36:37 +01:00
Earlopain
bca7d2cdd0
[Posts] HIde the pending info-notice when user can approve 2024-01-14 12:19:17 +01:00
Earlopain
cd188a797f
[Tests] Handle empty git hash
The app directory isn't marked as safe => a test fails for accessing nil
Not sure how there's only 1 test failing because of this.
Either way, this is more correct
2024-01-12 22:56:20 +00:00
Earlopain
3d1a53233b
[Docker] Reenable irb autocomplete
Feels much better than when I disabled this
2024-01-12 21:16:36 +00:00
Earlopain
0f1a96476e
[Docker] Give OpenSearch more time to start up 2024-01-12 20:52:00 +00:00
Earlopain
fa9fb531f7
[Docker] Add a devcontainer
This removes the need for all the ruby-lsp setup stuff.

ruby-lsp will try to install the debug gem which contains native code, add that to the gemfile so it doesn't cause trouble.

I'm probably going to remove the rubocop/test compose services at some point. With devcontainers you are just able to run the commands directly.
2024-01-12 20:50:24 +00:00
Earlopain
5c14472878
[Misc] Tweak readme
Also adds back something to .env.sample that I accidentally removed last commit.

The installation instructions to properly set up ruby-lsp are pretty convoluted at the moment,
I'm hoping that this will improve in the future. I openend https://github.com/Shopify/ruby-lsp/issues/1303 Let's see how that goes
2024-01-12 17:52:22 +01:00
Earlopain
a0a0d8db13
[Docker] Replace solargraph with ruby-lsp
It just works.
Requires a bit of a workaround for the .rubocop.yml env setup currently in use but thats alright.
The companion ruby-lsp-rails doesn't do much right now but I imagine that to become quite powerful in the future.
2024-01-11 23:16:03 +01:00
Earlopain
7c53f9331b
Merge pull request #584 from Sindrake/post-toolbar-fix
[Posts] Fix post toolbar styles on mobile devices
2024-01-11 19:29:00 +01:00
Sindrake
bbd5ca5a39 [Posts] Add icons to some toolbar buttons 2024-01-11 09:51:03 -08:00
Earlopain
2c03ccf681
Merge pull request #581 from DonovanDMC/add-user-feedback-updater
[UserFeedback] Add Updater
2024-01-11 17:29:45 +01:00
Earlopain
40792f6d43
[Discord] Add moderator report 2024-01-09 17:24:48 +01:00
Earlopain
3e1af2183a
[Discord] Move some things for discord webhook to base class 2024-01-09 17:12:43 +01:00
Earlopain
a12b8d0d03
[Users] Remove outdated note about hidden favs in settings 2024-01-09 17:12:33 +01:00
Sindrake
21759d0845 [Posts] Fix post toolbar styles on mobile devices 2024-01-06 08:46:07 -08:00
Donovan Daniels
c11ad6b874
[UserFeedback] Add Updater 2024-01-04 14:31:54 -06:00
Donovan Daniels
21facdd638
[PostSets] require post_ids[] for adding/removing posts 2024-01-04 14:24:45 -06:00
Donovan Daniels
330fb7cb8b
[DMails] Return no content in api instead of redirecting (#575)
* [DMails] Return no content in api instead of redirecting

* Expand `fmt`, remove explicit 204
2024-01-04 17:53:16 +01:00
Earlopain
be9fca4198
Merge pull request #577 from DonovanDMC/forum-topics-mark-as-read-json
[ForumTopics] Return no content instead of redirecting when marking all as read
2024-01-03 15:57:49 +01:00
Earlopain
95003d2014
Merge pull request #578 from DonovanDMC/fix-uploads-parent_id-search
[Uploads] Fix parent_id search
2024-01-03 15:56:34 +01:00
Earlopain
ea53b3d925
Merge pull request #579 from DonovanDMC/cub-is-dead
[Uploader] Remove cub from contentious examples
2024-01-03 15:56:18 +01:00
Donovan Daniels
8b3b7c7051
[Uploader] Remove cub from contentious examples 2023-12-28 22:10:12 -06:00
Donovan Daniels
bce86389b0
[Uploads] Fix parent_id search 2023-12-22 19:13:52 -06:00
Donovan Daniels
7e9c4eaa90
[ForumTopics] Return no content instead of redirecting when marking all as read 2023-12-20 23:19:13 -06:00
Donovan Daniels
53cea71422
[PostSets] Render expected error when post_ids[] is missing 2023-12-20 22:46:27 -06:00
Earlopain
acae76a907
[Dmails] Change http verb from post to put for marking as read
That's what mark_all_as_read should have been from the start and
what I should have put mark_as_read to as well
2023-12-18 20:03:38 +01:00
Earlopain
4106787487
[Gems] Remove explicit dependecy on resolv
It's a default gem and as such not needed there
2023-12-17 20:28:10 +01:00
Earlopain
c66e7c1f34
[Uploads] Allow underscore in whitelist entry 2023-12-17 20:16:58 +01:00
Earlopain
d4f72baf5f
[Comments] Disable the button on submit
Should hopefully do something against the constant double-submits
2023-12-17 20:11:59 +01:00
Earlopain
18f8f99730
[Dmails] Don't mark as read on show for API requests 2023-12-17 20:08:44 +01:00
Earlopain
f477141c63
[Dmails] Add route to mark single dmail read 2023-12-17 20:06:10 +01:00
Earlopain
16014a438f
[Dmails] Partially enable api
Basically everything except sending
2023-12-17 19:55:13 +01:00
Earlopain
50f5e3e77c
[Dmails] Put everything behind being member
See ef1db967f7, that's not applicable anymore.
There was no information leak.
2023-12-11 15:30:00 +01:00
Earlopain
acd1981773
[Forum] Add confirmation to unsticky and unlock 2023-12-08 17:00:50 +01:00
Earlopain
89acdd77a4
Merge pull request #566 from DonovanDMC/vote-management-links
[VoteManager]: Make links work
2023-12-08 16:55:50 +01:00
Earlopain
1322efc8cf
Merge pull request #565 from DonovanDMC/aibur-approval-confirmation
[TagRelationships]: Add approval confirmation
2023-12-08 16:54:56 +01:00
Donovan Daniels
d046c03ce0
[VoteManager]: Make links work 2023-12-07 08:32:23 -06:00
Donovan Daniels
7f3b403383
[TagRelationships]: Add approval confirmation 2023-12-07 08:27:06 -06:00
Earlopain
76a9b601b3
[Rubocop] Regenerate todo
1004 files inspected, 5443 offenses detected, 5197 offenses autocorrectable
2023-12-04 20:57:56 +01:00
Earlopain
d9bfd29b48
[Uploads] Fix missing paren in error message 2023-12-04 20:56:53 +01:00
Donovan Daniels
74007f2e30
[Blips] Add Updater & Tests/Move modactions to callbacks (#540)
* [Blips] Add `updater_id` & update notice

* [Blips] Move modaction generation logic into rails callbacks

* [Tests] Add blip tests

* Move update notice to right place

* Assert amount of difference

* Rebase oopsie

---------

Co-authored-by: Earlopain <14981592+Earlopain@users.noreply.github.com>
2023-12-04 20:56:14 +01:00
Donovan Daniels
fd5b491694
[UserWarnable] Fix warning_user_id never being set (#541)
* [UserWarnable] fix `warning_user_id` never being set
I know `update` & `update_columns` function differently, but I feel the difference isn't needed

* [UserWarnable] Add inline user and timestamp

* lint

* Move warning info into partial

Also removes the user/timestamp as that is redundant for now

* Fix unmarking

* Tweak fixer script

---------

Co-authored-by: Earlopain <14981592+Earlopain@users.noreply.github.com>
2023-12-04 20:19:49 +01:00
Donovan Daniels
6eaf435002
Bring ForumPost ModAction trigger in line with Comments (#542)
* [Tests] Add hide & delete modaction tests to comments and forum posts

* [ForumPosts] Remove user id check on destroy

* [ForumPosts] Don't create edit modaction on hide

* Assert correct amount of ModActions is created

Especially important when it previously created 2 instead of 1 for hiding

---------

Co-authored-by: Earlopain <14981592+Earlopain@users.noreply.github.com>
2023-12-04 19:41:29 +01:00
Earlopain
8bec207580
[Bans] Add edit link to secondary links 2023-12-04 19:17:04 +01:00
Donovan Daniels
b330a5f579
[ModActions] Ban Update Mod Action (#539)
* [ModActions] Ban Update Mod Action

* Add back accidentally removed newline

* Log expiration for user_ban_update ModAction

The duration in days makes sense on creation but it falls apart when updating
For this to correctly work the duration needs to be persisted as well
which it isn't at the moment.

---------

Co-authored-by: Earlopain <14981592+Earlopain@users.noreply.github.com>
2023-12-04 19:09:35 +01:00
Donovan Daniels
10e9304f17
[ForumPosts] Check for existence of topic & category (#524)
* [ForumPosts] Check for existence of topic & category

* [Tests] Add invalid topic category_id test

* Tweak how it is getting validated

If the category doesn't exist there's not point in doing anything further

* Move response assert before the other one

Should always be that way. If the response doesn't have the expected format
the assert will for sure fail and produce a confusing error message

---------

Co-authored-by: Earlopain <14981592+Earlopain@users.noreply.github.com>
2023-12-04 18:03:11 +01:00
Earlopain
0958724683
Merge pull request #561 from mm12/ApproverRelatedLinks
Add links for approvers in Post/Related
2023-12-04 17:29:58 +01:00