def log!
      Decidim::ActionLog.create!(
        user: user,
        organization: organization,
        action: action,
        resource: resource,
        resource_id: resource.id,
        resource_type: resource.class.name,
        participatory_space: participatory_space,
        component: component,
        area: area,
        scope: scope,
        version_id: version_id,
        extra: extra_data,
        visibility: visibility
      )
    end
def log!
      Decidim::ActionLog.create!(
        user: user,
        organization: organization,
        action: action,
        resource: resource,
        resource_id: resource.id,
        resource_type: resource.class.name,
        participatory_space: participatory_space,
        component: component,
        area: area,
        scope: scope,
        version_id: version_id,
        extra: extra_data,
        visibility: visibility
      )
    end
Public: Initializes the instance.

 action - a String representing the name of the action
 user - the Decidim::User that performed the action
 resource - the resource onn which the action was performed
 version_id - the ID of the `PaperTrail::Version` that was created on that action
 resource_extra - a Hash with resource_extra info to be recorded
 Public: Logs the given `action` by the given `user` on the given
 `resource`.

 Returns the newly created `Decidim::ActionLog` resource.