lib/cassandra/helpers.rb in cassandra-0.9.1 vs lib/cassandra/helpers.rb in cassandra-0.10.0
- old
+ new
@@ -15,9 +15,10 @@
options.merge!(args.pop)
end
# Ranges
column, sub_column = args[0], args[1]
+ raise ArgumentError, "Invalid arguments: subcolumns specified for a non-supercolumn family" if sub_column && !is_super(column_family)
klass, sub_klass = column_name_class(column_family), sub_column_name_class(column_family)
range_class = column ? sub_klass : klass
[:start, :finish].each do |opt|
options[opt] = options[opt] ? range_class.new(options[opt]).to_s : ''