public
Description: When Active Record objects are saved from a form, empty fields are saved as empty strings instead of nil. This kills most validations.
Homepage:
Clone URL: git://github.com/collectiveidea/clear_empty_attributes.git
Click here to lend your support to: clear_empty_attributes and make a donation at www.pledgie.com !
brandon (author)
Thu Jan 15 22:18:57 -0800 2009
commit  3a8f3c2e09bc953e9b5b76b5101c3691cb84a9b2
tree    5d41d3edb2e994fbcb934fe1fe34d0e977b12acb
parent  e1d504c76e9a133d4f7c89748c6302066cdbd774
clear_empty_attributes / clear_empty_attributes.gemspec
100644 38 lines (33 sloc) 1.737 kb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
# -*- encoding: utf-8 -*-
 
Gem::Specification.new do |s|
  s.name = %q{clear_empty_attributes}
  s.version = "0.1"
 
  s.required_rubygems_version = Gem::Requirement.new(">= 1.2") if s.respond_to? :required_rubygems_version=
  s.authors = ["Brandon Keepers"]
  s.date = %q{2009-01-16}
  s.description = %q{Save empty strings as nil to avoid lots of problems}
  s.email = %q{brandon@opensoul.org}
  s.extra_rdoc_files = ["lib/clear_empty_attributes.rb", "README.markdown", "tasks/clear_empty_attributes.rake"]
  s.files = ["clear_empty_attributes.gemspec", "init.rb", "lib/clear_empty_attributes.rb", "Rakefile", "README.markdown", "spec/clear_empty_attributes_spec.rb", "spec/setup_test_model.rb", "spec/spec_helper.rb", "tasks/clear_empty_attributes.rake", "Manifest"]
  s.has_rdoc = true
  s.homepage = %q{http://github.com/collectiveidea/clear_empty_attributes}
  s.rdoc_options = ["--line-numbers", "--inline-source", "--title", "Clear_empty_attributes", "--main", "README.markdown"]
  s.require_paths = ["lib"]
  s.rubyforge_project = %q{clear_empty_attributes}
  s.rubygems_version = %q{1.3.1}
  s.summary = %q{Save empty strings as nil to avoid lots of problems}
 
  if s.respond_to? :specification_version then
    current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
    s.specification_version = 2
 
    if Gem::Version.new(Gem::RubyGemsVersion) >= Gem::Version.new('1.2.0') then
      s.add_runtime_dependency(%q<activerecord>, [">= 0"])
      s.add_development_dependency(%q<echoe>, [">= 0"])
    else
      s.add_dependency(%q<activerecord>, [">= 0"])
      s.add_dependency(%q<echoe>, [">= 0"])
    end
  else
    s.add_dependency(%q<activerecord>, [">= 0"])
    s.add_dependency(%q<echoe>, [">= 0"])
  end
end