Commit Graph
1071 Commits
Author SHA1 Message Date
evazion c78dece411 tag corrections: remove distributed cache logic (#3943).
Remove logic for displaying the state of the tag category cache on both
servers.
2018-10-04 13:46:10 -05:00
evazion 151fa00933 tests: fix tests for /comments/new, /post_flags/new. 2018-10-01 10:38:15 -05:00
evazion dfb7cf6994 comments: add standalone new comment form.
Add standalone /comments/new page to allow commenting if javascript is
disabled.
2018-09-29 20:42:38 -05:00
evazion 9ac59aeadd comments.js: clean up comment quoting.
Replace Comment.quote with a remote new.js.erb call.
2018-09-29 20:42:38 -05:00
evazion f886f2fdb3 posts/show: load flag/appeal/replacement dialogs via ajax (#3922). 2018-09-26 20:01:14 -05:00
evazion 6fe883c316 posts index: clean up limit:<n> / order:random parsing (#2894)
* Move the limit:<n> / order:random metatag parsing from the controller
  to the post set.

* Introduce `Tag.has_metatag?` and use it to parse these metatags
  instead of using a regex (#2894).
2018-09-20 19:23:47 -05:00
evazion 235271706b Fix #3913: Remove legacy /post/create.xml endpoint. 2018-09-20 12:25:16 -05:00
Albert Yi ed5b2ad443 throw error on counts/posts endpoint during a timeout (#2170) 2018-09-19 13:34:50 -07:00
evazion 1fce794b99 artist urls: add /artist_urls index page. 2018-09-15 19:58:05 -05:00
evazion 10ca4dd3ad artists: replace artist finder with fetch source data.
* On posts, automatically trigger "Fetch source data" when clicking the
  Edit tab, instead of triggering the artist finder button. This way we
  find both the artist and the translated tags in one ajax call.

* Remove the "Artist" finder button next to the source field. This isn't
  necessary given that "Fetch source data" finds the artist itself.

* Remove the /artists/finder.json API endpoint. This is no longer used
  after removing the "Artist" finder button.
2018-09-11 20:09:25 -05:00
Albert Yi 42f7b17a30 Merge pull request #3883 from evazion/refactor-anonymous-user
Refactor AnonymousUser
2018-09-11 12:09:25 -07:00
evazion de10ea66a1 <role>_only: fix role checking logic to check ip bans last.
Make <role>_only methods check the role first and ip bans last. This
avoids hitting the database for anonymous users, since they'll always
fail the is_<role>? check before the ip check.
2018-09-09 21:53:24 -05:00
evazion 056fe365f2 Render "Fetch source data" box html server-side.
Instead of calling /sources.json and rendering the "Fetch source data"
box client-side in Javascript, call /sources.js so we can render the
html server-side.
2018-09-08 15:42:16 -05:00
evazion 950fcdb7b2 uploads: add new source:<url> dupe check (fix #3873)
* On the /uploads/new page, instead of just showing a "This post has
probably already been uploaded" message, show the actual thumbnails of
posts having the same source as what the user is trying to upload.

* Move the iqdb results section up top, beside the related posts section.
2018-09-06 20:43:20 -05:00
evazion 07c0695ac1 uploads: remove "this post was probably already uploaded" dupe check.
Also makes it so that using the bookmarklet always triggers async upload
preprocessing. Before it was only triggered when the source passed a
dupe check, but that check was inaccurate (#3873).
2018-09-06 20:43:04 -05:00
Albert Yi e5010bebf9 allow reportbooru to update post counts 2018-09-05 14:04:46 -07:00
r888888888 7f85dd27f9 use image url for iqdb proxy 2018-08-29 20:56:24 -07:00
Albert Yi 64c3bc18a7 rename ref and url fields to upload_source and upload_referer_url 2018-08-29 16:46:04 -07:00
Albert Yi 66e413b540 Adds fuzzy string matching and prefix matching 2018-08-28 16:41:52 -07:00
Albert Yi 68c30961ac Merge pull request #3805 from r888888888/refactor-sources
Refactor sources
2018-08-28 12:13:15 -07:00
evazion 6ff70c5002 mod actions: separate account upgrades from promotions (fix #3841) 2018-08-26 11:12:04 -05:00
evazion 3dafca9aec Fix #3842: Mods can demote other mods or admins. 2018-08-25 13:52:50 -05:00
Albert Yi 762dc3da24 Refactor sources 2018-08-24 12:10:51 -07:00
evazion 05ad112831 Fix #3835: Related tags update vulnerability.
Also fixes deprecated call to `render :text`.
2018-08-24 12:16:23 -05:00
evazion eef8b9c323 posts/show: fix flash message when faving/unfaving posts.
Bug: if you faved a post, then opened another page in a separate tab,
then the "You have favorited this post" flash message would appear in
the separate tab.

Fixes regression in bcaee199.
2018-08-15 20:14:51 -05:00
Albert Yi 0314dc9751 more consistent behavior of CurrentUser.root_url 2018-08-15 16:08:10 -07:00
evazion bcaee199f5 favorites: unify create.js.erb & destory.js.erb code paths. 2018-08-12 15:51:18 -05:00
evazion fb91bbc6c5 Fix #3813: Favorite limit can be bypassed. 2018-08-12 14:22:08 -05:00
evazion 130570aa33 comments.js: fix thresholded comments.
* Restore behavior of thresholded comments being greyed out (lost in 6fa0ae2cf).

* Set the `below-threshold` class for thresholded comments in the html instead of in javascript.

* Remove `include_below_threshold` param; it was always true when clicking "Show all comments".
2018-08-09 14:45:26 -05:00
Albert Yi 718e641f51 remove similar users report 2018-08-03 17:40:00 -07:00
r888888888 cafd952cc5 fix self check for rec posts 2018-07-21 14:35:24 -07:00
r888888888 344c46ed00 add mock recommender service for development, add user-context recommended posts 2018-07-21 14:02:57 -07:00
Albert Yi 9cfb629891 rename similar posts to recommended posts, refactor menu on posts/show 2018-07-20 16:36:14 -07:00
Albert Yi df6e86551a tweaks to similar posts 2018-07-20 15:05:51 -07:00
Albert Yi 6fb20fca89 bug fixes with storage manager 2018-07-20 14:47:58 -07:00
Albert Yi abcef9115b fix tests 2018-07-20 13:52:56 -07:00
Albert Yi 93f52adc81 fixes #3768 2018-07-20 11:51:42 -07:00
Albert Yi 89e2071c14 remove unused code 2018-07-05 16:59:28 -07:00
Albert Yi cdcd4d4014 Add additional post flag validation preventing targeting 2018-06-26 15:09:39 -07:00
r888888888 5aae4b649f add xhr variant detection 2018-06-23 12:09:01 -07:00
r888888888 3ba5c6fb51 refactor iqdb endpoints 2018-06-23 10:59:04 -07:00
Albert Yi 56b40a0255 add iqdb preview 2018-06-22 16:41:13 -07:00
Albert Yi e262295cf1 support json for iqdb query actions 2018-06-20 11:53:44 -07:00
Albert Yi 28663351d1 fixes #3757 2018-06-20 11:27:49 -07:00
Albert Yi 56ee44dc00 fixes to iqdb queries 2018-06-20 10:00:05 -07:00
Albert Yi ed46e575c0 support url/post_id params on iqdb queries endpoint 2018-06-19 17:06:17 -07:00
Albert Yi 9510dead9f refactor iqdb query support 2018-06-19 14:16:12 -07:00
Albert Yi 0e6c358701 add drag and drop file uploads w/async processing
[skip ci]
2018-06-14 17:52:41 -07:00
Albert Yi fdd7582fb0 add support for upload preprocessing 2018-06-14 17:52:41 -07:00
Albert Yi c75f520055 fixes #3730 2018-06-05 14:48:09 -07:00