File 0001-Remove-accidental-file-add.patch of Package rubygem-acts-as-taggable-on
From f836c911ef29dc432b9b6a58cbdfe53f89e9f09e Mon Sep 17 00:00:00 2001
From: Tom-Eric <ik@tom-eric.info>
Date: Wed, 19 May 2010 15:49:21 +0200
Subject: [PATCH 1/9] Remove accidental file add
---
.../compatibility/postgresql.rb | 44 --------------------
1 files changed, 0 insertions(+), 44 deletions(-)
delete mode 100644 lib/acts_as_taggable_on/compatibility/postgresql.rb
diff --git a/lib/acts_as_taggable_on/compatibility/postgresql.rb b/lib/acts_as_taggable_on/compatibility/postgresql.rb
deleted file mode 100644
index 1f7f496..0000000
--- a/lib/acts_as_taggable_on/compatibility/postgresql.rb
+++ /dev/null
@@ -1,44 +0,0 @@
-module ActsAsTaggableOn
- module Taggable
- module PostgreSQL
- def self.included(base)
- base.send :include, ActsAsTaggableOn::Taggable::PostgreSQL::InstanceMethods
- base.extend ActsAsTaggableOn::Taggable::PostgreSQL::ClassMethods
-
- ActsAsTaggableOn::Tag.class_eval do
- def self.named(name)
- where(["name ILIKE ?", name])
- end
-
- def self.named_any(list)
- where(list.map { |tag| sanitize_sql(["name ILIKE ?", tag.to_s]) }.join(" OR "))
- end
-
- def self.named_like(name)
- where(["name ILIKE ?", "%#{name}%"])
- end
-
- def self.named_like_any(list)
- where(list.map { |tag| sanitize_sql(["name ILIKE ?", "%#{tag.to_s}%"]) }.join(" OR "))
- end
- end
- end
-
- module InstanceMethods
- end
-
- module ClassMethods
- # all column names are necessary for PostgreSQL group clause
- def grouped_column_names_for(*objects)
- object = objects.shift
- columns = object.column_names.map { |column| "#{object.table_name}.#{column}" }
- columns << objects.map do |object|
- "#{object.table_name}.created_at"
- end.flatten
-
- columns.flatten.join(", ")
- end
- end
- end
- end
-end
\ No newline at end of file
--
1.7.1