Commit graph

217 commits

Author SHA1 Message Date
Shish
b2f10ea5ab split up files in core/ for saner management 2018-11-05 22:30:18 +00:00
Shish
38406ef33a block tags starting with minus 2018-08-22 21:56:27 +01:00
Shish
840915c9f0 support for picking n'th item from the consistent hash 2018-07-26 00:26:01 +01:00
Shish
64e2f7fe53 query accelerator failures should silently fall back to non-accelerated mode 2018-07-19 19:31:37 +01:00
Shish
d4b28d7c07 fixup alias non-recursion 2018-07-16 08:46:01 +01:00
Shish
2417b5b021 don't recursively expand aliaes, as that can create loops 2018-07-15 19:39:39 +01:00
Shish
9e3e37a209 accelerate counts as well as the actual results 2018-06-30 14:28:52 +01:00
Shish
60c16a9139 dash in the middle of a tag isn't special, allow it to be accelerated 2018-06-20 02:40:52 +01:00
Shish
6aa704d04c better image counting 2017-09-21 05:49:10 +01:00
Shish
2628c2c5d9 Merge branch 'develop' of https://github.com/shish/shimmie2 into develop 2017-09-21 05:25:48 +01:00
Shish
6e914ff4e7 use just hash for flexihash lookup 2017-09-21 05:25:45 +01:00
Shish
977c3db1e3 PHP7 type annotations 2017-09-21 05:21:42 +01:00
Shish
35bd51e513 use 'count()' + result->get_one() to count images, rather than 'select *' + result->rowcount()... 2017-08-23 00:42:19 +01:00
Shish
843d7fae24 merge 2017-05-29 10:19:55 +01:00
Shish
684efedcfd Log what URL query caused invalid search queries 2017-05-29 10:16:32 +01:00
jgen
f492c6c2c3 Ensure that the Image object tag_array and the metadata array tags are always arrays. 2017-05-12 00:57:50 -07:00
Thomas Hori
d1306cfb2d Move Tag::explode call into add_image call so that $result is unaffected. 2017-04-26 14:08:06 +01:00
Thomas Hori
1625bd68e3 Fix error upon bulk add.
Fixes "PHP Fatal error:  Uncaught TypeError: Argument 2 passed to
TagSetEvent::__construct() must be of the type array, string given"
upon bulk add.
2017-04-25 17:48:34 +01:00
jgen
7bd581b530 Scrutinizer commets. 2017-03-12 14:29:35 -07:00
jgen
8de816d7dd Some more linting via PHPDoc comments. 2017-03-12 00:18:26 -08:00
Shish
c208a3715c mark static functions as static 2017-03-10 16:14:56 +00:00
jgen
17307820e8 Add some PHPdoc comments as suggested by Scrutinizier 2017-03-08 23:02:26 -08:00
Shish
bcef3fbc8f have tag sanitisation process ignore tags which are too long, fixes #565 2016-08-29 09:21:23 +01:00
Shish
7be951b271 Convert tags from user-supplied string to array once, on input
This results in a fuckton of refactoring and code cancelling out
other code -- we no longer have a whole bunch of places trying
to support string params and array params, and doing their own
esaping and unescaping, never being quite sure if the data they've
been passed is escaped or not.

Also adds a bunch of type hinting, since we can now know what
data we're dealing with better.
2016-07-30 22:11:49 +01:00
Shish
b6ad316d20 linting 2016-07-03 12:07:54 +01:00
Shish
d185fd354b fix wildcard search for mysql 2016-06-19 12:14:44 +01:00
Shish
e0d3d53479 stub mb_ functions 2016-06-19 12:12:48 +01:00
Daku
dd105e174e images aren't always jpg, so don't force jpg
all the handle_* exts use this as well, which can cause issues
2016-06-18 06:20:46 +01:00
Daku
895df8c22b load flexihash via composer 2016-06-18 06:16:28 +01:00
Shish
bfa1dc20c0 fix mysql 2016-06-07 01:50:56 +01:00
Shish
8e8a3da790 support single wildcard 2016-06-07 01:39:23 +01:00
Shish
dc83d4ace7 lots of deduping for searching 2016-06-07 01:34:38 +01:00
Shish
7f2609f727 dedupe searching a bit 2016-06-07 00:19:41 +01:00
Daku
61acb24875 fixes #547 -> multi-tag searches not working with wildcard when wildcard matches more than 1 tag
is there a better way to do this?
2016-05-22 18:35:37 +01:00
Daku
3b171ffc5a fix single tag wildcard searches returning duplicate results if image has more than one match 2016-05-22 17:58:09 +01:00
Daku
6d1c7c414b mysql < 5.6 has terrible subquery optimization, using EXISTS / JOIN fixes this 2015-12-04 11:38:44 +00:00
Daku
600011219f update docs 2015-10-08 19:25:38 +01:00
Daku
43d0a297b8 move metatag parsing to after set_tags is sent, rather than before 2015-10-08 18:58:52 +01:00
Daku
b11041898b Tag::explode instead of explode
this fixes the off chance that an empty tag could be passed
2015-10-08 18:28:00 +01:00
Daku
744989a983 Tag::explode should now remove duplicate tags 2015-10-08 18:25:03 +01:00
Daku
6ff80ab2c8 move tag sanitization, alias checking & tag parsing to TagSetEvent 2015-10-08 18:22:20 +01:00
Shish
d30665d274 more deduping 2015-09-27 21:09:27 +01:00
Shish
cdcd762a52 more comments 2015-09-27 02:17:44 +01:00
Shish
ec484c1144 more phpunit-ing 2015-09-20 20:04:13 +01:00
Shish
35a4f385b3 phpstorm tidying 2015-09-12 11:43:28 +01:00
Daku
ef6a7289bb if alias is negative and has multiple tags, make sure each tag becomes negative 2015-08-12 06:11:21 +01:00
Shish
18490ed488 more global removal 2015-08-02 20:39:41 +01:00
Shish
e2b6f2c2dd global management 2015-08-02 19:41:06 +01:00
Shish
e5e7f891e2 scrutinizer suggestions 2015-07-21 01:20:53 +01:00
Shish
9508bec8d3 whyyyyy 2015-07-21 01:00:13 +01:00