Nutomic
e1494d4683
Dont compare db string errors ( fixes #1393 ) ( #3424 )
...
* Dont compare db string errors (fixes #1393 )
* cargo fmt
---------
Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2023-07-03 11:59:49 -04:00
Simon Bordeyne
b8ee9315bc
Add Open links in new tab setting ( #3318 )
...
* Add Open links in new tab setting
* reorder because it fixes tests ?
2023-07-03 11:10:25 -04:00
Nutomic
cb91eedd24
Use serde(skip) instead of skip_serializing, add placeholder values ( #3362 )
...
* Use serde(skip) instead of skip_serializing
The latter breaks lemmy_crawler as the field is not included in
the Lemmy API, but is required when attempting to parse API responses.
Should only use serde(skip) to avoid this problem
* use option
* add placeholders
* no unwrap
2023-07-03 15:14:01 +02:00
Nutomic
6405761891
Mark follow as pending when subscribing to remote community ( fixes #3384 ) ( #3406 )
2023-07-03 12:03:20 +02:00
Felix Ableitner
fc60b82f82
Fix formatting for latest nightly (#ref 3467)
2023-07-03 11:45:53 +02:00
Nutomic
3578dab67f
Remove PerformApub trait ( #3423 )
...
* Remove PerformApub trait
This is completely useless now that websocket is gone. In the future
I also plan to remove Perform and PerformCrud traits, but it will be
difficult to do that while still compiling crates in parallel.
* params need to use query
2023-07-03 11:01:41 +02:00
phiresky
cb28af508d
don't strip, log trace if requested ( #3425 )
2023-06-30 09:32:43 -04:00
Lemmus.org
810762762f
Update federated posts to not cache sensitive images if not allow by local site ( #3253 )
...
* Update federated posts to not cache sensitive images if not allow by local site
* Refactor thumbnail match to simplify logic
2023-06-30 12:42:42 +02:00
Dominic Mazzoni
fcc010b5dc
Fix concatenation of audio captcha wav files ( #3350 )
...
* Fix concatenation of audio captcha wav files
* Log errors rather than crashing
* Return Result from captcha_as_wav_base64
* Change to return LemmyError
* Check for wav write error, format
* Remove unused import
* Rewrite to avoid clippy warnings
2023-06-30 12:36:38 +02:00
Dessalines
6c64cb5233
Fixing release script. ( #3398 )
...
* Fixing release script.
* Version 0.18.1-rc.2
* Removing cargo update from release script.
* Fixing topdir location.
2023-06-29 16:17:59 +02:00
Sander Saarend
ec18fd9869
Fix cargo warnings ( #3397 )
2023-06-28 12:57:49 -04:00
Jan Klass
0f91759e4d
docs(api): Add api-common info on generating TypeScript bindings ( #3330 )
2023-06-28 11:25:46 +02:00
dullbananas
bef76630c5
Remove redundant calls to `Iterator::collect` ( #3365 )
...
* Remove redundant calls to `Iterator::collect`
* Update mentions.rs
* Add clippy lints and run fmt
* CI ran on the wrong commit again
2023-06-28 11:19:26 +02:00
Dessalines
ad6f244b61
Version 0.18.1-rc.1
2023-06-27 08:14:46 -04:00
Nina Blanson
e63aa80c3a
Fixes #2900 - Checks slur regex to see if it is too permissive ( #3146 )
...
* Fixes #2900 - Checks slur regex to see if it is too permissive along with small validation organization
* Clean up variable names, add handler for valid empty string usecase
* Update tests
* Create validation function and add tests
* Test clean up
* Use payload value vs local site value to prevent stunlocking
* Remove println added while testing
* Fall back to local site regex if not provided from request
* Attempt clean up of flaky comment_view tests
* Pull in latest submodule
* Move application, post check into functions, add more tests and improve test readability
---------
Co-authored-by: Nutomic <me@nutomic.com>
2023-06-27 07:03:30 -04:00
Domenic Horner
d1d90af0eb
add new flag to api ( #3363 )
2023-06-27 06:45:26 -04:00
TKilFree
2aef6a5a33
feat: re-added captcha checks ( #3289 )
2023-06-27 06:38:53 -04:00
Sander Saarend
76a4513774
Limit password resets ( #3344 )
2023-06-27 11:20:53 +02:00
c-andy-candies
f5209fffc1
Feature add three six and nine months options backend ( #3226 )
...
Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2023-06-26 15:03:35 -04:00
Nutomic
50efb1d519
Fetch community outbox and moderators in parallel ( #3360 )
...
This will speedup first time fetching of a remote community
2023-06-26 12:14:50 -04:00
Simon Lundström
c9e9ff46fa
Item URL should point to post URL ( #3345 )
...
If the post is an URL post the item link should point to the URL of the
link that is being posted.
2023-06-26 15:11:16 +02:00
Otto Rottier
62c8ac1db5
Site Metadata: resolve relative URLs for embedded images/videos ( #3338 )
...
* Site Metadata: resolve relative URLs for embedded images/videos
* api_common: relax version requirement of `webpage` dependency
With this change we opt into next (non breaking) versions of webpage-rs
* cargo +nightly fmt
* Add tests for resolving absolute urls in SiteMetadata
2023-06-26 15:07:57 +02:00
Felix Ableitner
73d2faa9f5
Remove another unused dev dependency
2023-06-26 12:46:44 +02:00
cetra3
9406c3ad2b
Adjust the config check to be a separate faster to compile binary ( #3313 )
2023-06-26 06:23:21 -04:00
perillamint
3d7d6b2530
Respond with `Content-Type: application/activity+json` ( #3353 )
...
As per ActivityPub specification, the return type should be
`application/activity+json`, not `application/json`.
2023-06-26 12:10:04 +02:00
Nutomic
ddfa112e0b
Allow wildcard imports in schema.rs ( #3293 )
...
Dont mess with auto-generated code, this avoids problems with
clippy after running diesel commands
2023-06-26 11:18:29 +02:00
Scott
c5886404ef
Update DB local_user.theme type to text ( #3266 )
...
* Update local_user.theme type to text
* fix default value
* Undo auto generate changes
2023-06-26 10:53:04 +02:00
TKilFree
21d5349785
feat: allow all admins to purge content ( #3271 )
2023-06-26 10:47:39 +02:00
Neshura
203e35899e
Add separate Post check for is_valid_body_field ( #3263 )
...
* Add separate Post check for is_valid_body_field
* Modify is_valid_body_check for posts only
* Fix check var reinit in validation.rs
* Extra empty line to rerun woodpecker with changes
* Change Option to bool, add false to non-post calls
* Woodpecker trick.. again
* Probable rust_fmt fail fixed
* cargo_clippy changes
* Missing space between = and if
* Remove ; after body length checks
2023-06-26 10:47:01 +02:00
Felix Ableitner
ce0cf0e41b
Remove DELETED_REPLACEMENT_URL
2023-06-26 10:45:37 +02:00
Sander Saarend
6b28f8c616
Add support for sslmode=require for diesel-async DB connections ( #3189 )
2023-06-26 10:45:22 +02:00
cetra3
d6b580a530
Remove `actix_rt` & use standard tokio spawn ( #3158 )
...
* Remove `actix_rt` & use standard tokio spawn
* Adjust rust log back down
* Format correctly
* Update cargo lock
* Add DB settings
* Change name and update to latest rev
* Clean up formatting changes
* Move `worker_count` and `worker_retry_count` to settings
* Update defaults
* Use `0.4.4` instead of git branch
2023-06-26 10:45:22 +02:00
Dessalines
37a47de3a8
Revert "feat: re-added captcha checks ( #3249 )" ( #3288 )
...
This reverts commit 8a086c8240
.
2023-06-26 10:45:22 +02:00
Dessalines
b6cd1bde8e
Fixing removed posts showing. Fixes #2875 ( #3279 )
...
* Fixing removed posts showing. Fixes #2875
* Fixing clippy.
2023-06-26 10:45:22 +02:00
TKilFree
9537878519
feat: re-added captcha checks ( #3249 )
2023-06-26 10:45:22 +02:00
Vijay Ramesh
418bca78e1
Merge branch 'main' into clear_deleted_posts_comments
2023-06-22 09:59:43 -07:00
Nutomic
ffce66abb8
Update apub library to 0.4.4 ( #3258 )
...
Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2023-06-22 08:35:12 -04:00
Vijay Ramesh
0d576a8f23
Merge branch 'main' into clear_deleted_posts_comments
2023-06-21 13:35:37 -07:00
Scott
da3e3b6d8a
Ensure site can only either be a private instance or federated when creating or editing site ( #3237 )
...
* Add site visibility validation
* Fix formatting
* linter changes
* Update error message to match existing check
* Remove existing check
---------
Co-authored-by: Scott Merchant <97430840+scottmerchant@users.noreply.github.com>
2023-06-21 22:14:12 +02:00
Vijay Ramesh
4db65c191c
after 30 days post deletion, replace comment.content and post.body with 'Permanently Deleted'
2023-06-21 12:46:56 -07:00
Michał
4cdb9583e9
feat: allow overriding smtp_password with the LEMMY_SMTP_PASSWORD env var ( #3154 )
...
Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2023-06-21 13:36:42 -04:00
Nutomic
e3eda68147
Correct error messages if user registers with taken user/email ( #3093 )
...
* Correct error messages if user registers with taken user/email (fixes #2955 )
* exists
2023-06-21 05:26:07 -04:00
Dessalines
1ef095dd96
Fixing cross_post duplicates. Fixes #3233 ( #3234 )
2023-06-21 10:56:44 +02:00
JP Moresmau
a1beccf353
Add test to check reading and listing posts return my_vote ( #3215 )
2023-06-21 10:48:39 +02:00
dullbananas
45818fb4c5
Reduce memory usage of rate limiting ( #3111 )
...
* Reduce Vec allocations
* Optimize stuff
* Move embedded migrations to separate crate
* Revert "Move embedded migrations to separate crate"
This reverts commit 44b1049970
.
* clippy, fmt
* Shrink rate limit allowance to f32
* Initialize rate limit allowance directly
* Add removal of old rate limit buckets
* Improve readability
* Remove usage of is_okay_and for Rust 1.67 compatibility
* Add dhat-heap feature
* Fix api_benchmark.sh and add run_and_benchmark.sh
* Revert "Fix api_benchmark.sh and add run_and_benchmark.sh"
This reverts commit b4528e5b85
.
* Revert "Add dhat-heap feature"
This reverts commit 08e835d487
.
* Manually revert remaining stuff
* Use Ipv6Addr in RateLimitStorage
* Shrink last_checked in RateLimitBucket to 32 bits
* Fix rate_limit::get_ip
* Stuff (#1 )
* Update rate_limiter.rs
* Update mod.rs
* Update scheduled_tasks.rs
* Fix rate_limiter.rs
* Dullbananas patch 1 (#2 )
* Update rate_limiter.rs
* Update mod.rs
* Update scheduled_tasks.rs
* Fix rate_limiter.rs
* Rate limit IPv6 addresses in groups
* Fmt lib.rs
* woodpicker trigger
* Refactor and comment `check_rate_limit_full`
* Add `test_split_ipv6`
* Replace -2.0 with UNINITIALIZED_TOKEN_AMOUNT
* Add `test_rate_limiter`
---------
Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2023-06-21 10:28:20 +02:00
Dessalines
5ff221a2e4
Fixing comment_view unit tests. ( #3224 )
2023-06-20 14:14:08 -04:00
Sander Saarend
8ed3f3530e
Fix parameter ordering for new_report_subject string ( #3210 )
2023-06-20 11:24:04 -04:00
Ivo Barros
4d160461ce
Feature add hours as sorting options backend ( #3161 )
...
* add hours as sorting options
* ran cargo +nightly fmt
* woodpicker trigger
2023-06-20 16:05:43 +02:00
kartikynwa
dc36d9ed89
Don't check verified email when an admin logs in ( #3209 )
...
Workaround for instance admins getting locked out when they turn on
the email verification requirement without having verified their
own email.
Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2023-06-20 08:52:21 -04:00
Felix Ableitner
56de68c77a
Update translations
2023-06-20 10:59:27 +02:00