1
0
mirror of https://github.com/danbee/micropub.git synced 2025-03-04 08:59:13 +00:00

Accept single categories

This commit is contained in:
Daniel Barber 2019-11-12 21:25:52 -05:00
parent 9931199b8d
commit 7e728dcc2e
Signed by: danbarber
GPG Key ID: 931D8112E0103DD8

View File

@ -38,7 +38,11 @@ class Post
end
def categories
params["category"] || []
if params["category"].is_a?(Array)
params["category"] || []
else
[params["category"]].compact
end
end
def content