wiki icon indicating copy to clipboard operation
wiki copied to clipboard

Same tag different case on two pages causes an error

Open ccolella-mdc opened this issue 6 years ago • 4 comments

Describe the bug If you create two pages and put the same tag, but with different casing on each one, the second one will break and not be able to be created.

To Reproduce Steps to reproduce the behavior:

  1. Create a new page and add a tag
  2. Create another new page and add the same tag but use different capitalization
  3. When you click "Create" it will error and you will no longer be able to access the page

Expected behavior The page gets created with no errors.

I would expect case to be normalized if it will cause an issue to have two different casings

Screenshots N/A

Host Info (please complete the following information):

  • OS: Windows Server 2012 R2
  • Wiki.js version: 2.0.12
  • Database engine: MS SQL Server 2016

Additional context N/A

ccolella-mdc avatar Jan 10 '20 19:01 ccolella-mdc

This error is still present, and quite annoying to be fair. Any E.T.A on the fix?

diabeeto076 avatar Mar 25 '20 14:03 diabeeto076

Second that - it's causing us difficulty with getting adoption on our internal wiki as people are seeing errors when doing basic functions.

Also noticed that it's possible to save tags with leading and trailing whitespace. Would it be prudent to trim strings to prevent duplicates due to whitespace? Sure they're not true duplicates but at least visually they seem to be.

cytron201 avatar Apr 03 '20 09:04 cytron201

Yeah, tags are sort of problematic in wiki.js. From a usability perspective, tags should be normalized to lowercase to prevent the creation of multiple tags just because of a capitalization difference. My experience thus far is that eliminating the confusion of having tags like "linux" and "Linux" leading to different collections is a nearly universal good thing.

brewerc1 avatar Apr 09 '20 18:04 brewerc1

Fixed by 77548c8778bdd9e30379318d219fa892d5ffc112

Tags will now be normalized and trimmed.

NGPixel avatar Apr 10 '20 01:04 NGPixel