undr/influxdb-api

View on GitHub
lib/influxdb/api/extensions.rb

Summary

Maintainability
A
0 mins
Test Coverage
class Array
  class << self
    unless method_defined?(:wrap)
      def wrap(object)
        if object.nil?
          []
        elsif object.respond_to?(:to_ary)
          object.to_ary || [object]
        else
          [object]
        end
      end
    end
  end
end