Albert Yi
f16c3a3f40
fix nijie specs
2018-09-11 13:27:00 -07:00
Albert Yi
e58172483b
update iqdb after post replacements ( #3885 )
2018-09-11 12:24:15 -07:00
Albert Yi
42f7b17a30
Merge pull request #3883 from evazion/refactor-anonymous-user
...
Refactor AnonymousUser
2018-09-11 12:09:25 -07:00
Albert Yi
1351c8234c
Merge pull request #3878 from evazion/fix-fetch-source-rendering
...
Render "Fetch source data" box server-side
2018-09-11 12:08:48 -07:00
evazion
9a980367f6
twitter: normalize artist commentaries to nfkc ( #3719 )
...
Fixes hashtags not being interpreted when the author uses a fullwidth
number sign (#, U+FF03).
ref: https://github.com/r888888888/danbooru/issues/3719#issuecomment-419535610
2018-09-10 21:45:50 -05:00
evazion
a0ebd90409
Post#normalized_source: add hitomi.la url normalization.
2018-09-10 20:22:10 -05:00
evazion
bfed323988
deviantart: fix page_url for when api data is unavailable.
...
The api data is unavailable when we can't scrape the uuid, either
because the work is deleted or because the work is actually a sta.sh
upload and we weren't given the sta.sh page in the referer url.
2018-09-10 19:26:53 -05:00
evazion
c9300cc54e
sta.sh: add tests + docs.
2018-09-10 19:26:53 -05:00
evazion
7d5d098636
Fix #3877 : Add sta.sh strategy.
...
Co-authored-by: lllusion3469 <31420484+lllusion3469@users.noreply.github.com >
2018-09-10 19:26:47 -05:00
evazion
10358d4211
Fix #3881 : It has been reviewed by X moderators.“ message.
2018-09-10 17:39:49 -05: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
e546e52bd7
Replace AnonymousUser with User.new.
...
* Replace AnonymousUser null object with a readonly, unpersisted User object.
* Default always_resize_images to true (previously it was true for
anonymous users, but false for new members).
* Default comment_threshold to -1 for anonymous users (previously it was
0 for anonymous but -1 for new members).
2018-09-09 21:53:08 -05:00
evazion
cb2d85d925
twitter: fix profile_url for twitter.com/i/web/status/:id urls.
...
Fix profile_url returning nil for https://twitter.com/i/web/status/943446161586733056 .
2018-09-09 19:48:34 -05:00
evazion
0d7b7e6e85
twitter tests: fix dead tweet.
2018-09-09 14:10:43 -05:00
evazion
b924c2bb9c
nijie: fix artist url normalization.
2018-09-09 13:17:52 -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
Albert Yi
b1a9337897
Merge pull request #3875 from evazion/fix-3873
...
Fix #3873 : Batch bookmarklet for tumblr reports wrong posts as already uploaded
2018-09-07 14:15:24 -07:00
evazion
99a5e885e0
artist_url.rb: remove legacy artist url normalization code.
...
* `legacy_normalize` came from c6012535 , which is no longer a problem.
* `normalize_for_search` is only used for "[mass edit]" links
in artist entries. These links are a shortcut for performing a
`-artist_name source:<artist_url> -> artist_name` mass edit to tag
untagged artists, but this won't work for most sites these days.
2018-09-07 12:55:51 -05:00
evazion
8e7dd9e97f
artist_url.rb: remove unnecessary deviantart profile url normalization.
...
This is now handled in the source strategy.
2018-09-07 12:26:50 -05:00
evazion
a67edb8783
deviantart: fix artist finder for artist names with underscores.
...
Fix the artist finder for urls like this:
https://orig00.deviantart.net/4274/f/2010/230/8/a/pkmn_king_and_queen_by_mikoto_chan.jpg
that don't contain a deviantart id but do contain the artist name.
2018-09-07 12:23:48 -05:00
evazion
610391205f
deviantart: fix artist finder for profile urls missing the 'www'.
...
Fix the artist finder to work when the profile url in the artist entry
is missing the 'www'. Example:
https://deviantart.com/noizave
https://www.deviantart.com/noizave
2018-09-07 11:36:48 -05:00
evazion
22c27f8910
post previews: fix css for captioned post previews.
...
Captioned post previews (previews with the pool name, similarity, or
size beneath) need to have `height: auto` set, otherwise they'll default
to `height: 154px` (just enough for the image) and the caption won't be visible.
2018-09-06 20:44:47 -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
evazion
06cf32160b
user.rb: memoize upload limit methods.
...
These methods get called multiple times when rendering UserPresenter#upload_limit
on the upload page. This caused repeated COUNT(*) queries.
2018-09-06 20:31:51 -05:00
evazion
7ecf6f1ba2
Fix link colors inside dialogs, autocomplete.
...
ref: f9f0da054 , https://github.com/r888888888/danbooru/issues/3791#issuecomment-410378703 .
2018-09-05 23:48:51 -05:00
evazion
aee1906761
Fix #3738 : Artist URL search should be case-insensitive for domains.
2018-09-05 19:14:24 -05:00
evazion
c2cf6a5441
Fix #3871 : Autocomplete can return duplicate tags.
2018-09-05 18:56:30 -05:00
Albert Yi
4b9f3e384f
include more messaging for user feedback
2018-09-05 16:32:18 -07:00
Albert Yi
22e30186b1
add min bound for post count fixing
2018-09-05 14:08:05 -07:00
Albert Yi
e5010bebf9
allow reportbooru to update post counts
2018-09-05 14:04:46 -07:00
Albert Yi
f9f0da0543
fix link colors in notices
2018-09-05 14:04:46 -07:00
Albert Yi
69b7c9efd0
Merge pull request #3838 from evazion/fix-3837
...
Fix #3837 : Remove expired bans.
2018-09-05 12:03:46 -07:00
Albert Yi
a41d006380
fix pool ordering js ( #3869 ), fix forum topic tests
2018-09-05 12:01:59 -07:00
Albert Yi
a774c6753b
show only 10 results in tag autocomplete
2018-09-05 11:17:22 -07:00
Albert Yi
f88cb1340a
tweak result counts for autocomplete
2018-09-05 11:08:22 -07:00
Albert Yi
3025db66d7
switch fuzzy autocomplete to spellcorrect intent
2018-09-05 09:41:25 -07:00
Albert Yi
314341773c
fix tests
2018-09-04 18:23:49 -07:00
Albert Yi
865e3dc976
switch back to similarity function for fuzzy search
2018-09-04 18:23:49 -07:00
evazion
6c457c86ac
nav menu: fix 'Forum' link not getting '.current' class.
...
Fixes the '.current' class not being set on the 'Forum' link when
viewing the /forum_topics page. As a result, the link wasn't bolded and
didn't have the background set.
2018-09-04 18:15:21 -05:00
evazion
5c457fbe51
pixiv: remove obsolete edgesuite.net rewrite rule.
...
This CDN hasn't been seen for several years.
ref: https://danbooru.donmai.us/forum_topics/10766
2018-09-04 18:15:21 -05:00
evazion
4bbe09762d
pixiv: remove dead methods (#is_manga?, #page_count, #page).
2018-09-04 18:15:21 -05:00
Albert Yi
c3b17f5fcc
Revert "remove global danbooru object js in default layout"
...
This reverts commit 68e7de1fc4 .
2018-09-04 14:26:37 -07:00
Albert Yi
3987f45362
fix autocomplete
2018-09-04 14:22:37 -07:00
Albert Yi
68e7de1fc4
remove global danbooru object js in default layout
2018-09-04 14:08:37 -07:00
Albert Yi
30a5d745a0
additional spec fixes
2018-09-04 14:01:35 -07:00
Albert Yi
13c2b4f5d0
add exception handling for failed popular search service calls
2018-09-04 13:44:51 -07:00
Albert Yi
a5943de418
Merge pull request #3868 from evazion/fix-3864
...
Fix #3864 : DeviantArt fetch source data failure
2018-09-04 13:42:01 -07:00
Albert Yi
8ec96f42f7
fix specs
2018-09-04 13:38:09 -07:00
Albert Yi
0529ec9ad0
Merge pull request #3862 from evazion/fix-3857
...
Refactor searching text attributes
2018-09-04 13:25:40 -07:00