mirror of
https://github.com/discourse/discourse.git
synced 2025-05-22 16:11:08 +08:00
FIX: Make category slug validation less strict (#8915)
This was changed recently and caused issues saving old categories which already had digits at the beginning of the slug (for example, '30-days').
This commit is contained in:
@ -324,7 +324,7 @@ class ListController < ApplicationController
|
||||
end
|
||||
|
||||
# Legacy paths
|
||||
if @category.nil? && parts.last =~ /\A\d+-/
|
||||
if @category.nil? && parts.last =~ /\A\d+-category/
|
||||
@category = Category.find_by_id(parts.last.to_i)
|
||||
end
|
||||
end
|
||||
|
Reference in New Issue
Block a user