diff --git a/lib/adamantium/micropub_request_parser.rb b/lib/adamantium/micropub_request_parser.rb index ad67793..61f2c33 100644 --- a/lib/adamantium/micropub_request_parser.rb +++ b/lib/adamantium/micropub_request_parser.rb @@ -2,7 +2,7 @@ require "securerandom" module Adamantium class MicropubRequestParser - include Deps["post_utilities.slugify", "repos.post_repo"] + include Deps["logger", "post_utilities.slugify", "repos.post_repo"] def call(params:) return nil if params.key?(:action) @@ -61,7 +61,6 @@ module Adamantium new_params[:content] = params[:properties][:content]&.first&.tr("\n", " ") new_params[:slug] = params[:slug] || params["mp-slug"] new_params[:syndicate_to] = params[:properties][:"mp-syndicate-to"] || [] - else new_params[:syndicate_to] = params[:"mp-syndicate-to"]&.split(",") || [] new_params[:name] = params[:name] @@ -82,6 +81,8 @@ module Adamantium new_params[:url] = params[:"bookmark-of"] new_params[:slug] = slug(name: new_params[:name], default_slug: params[:slug]) + logger.info(new_params) + new_params end end