webs 0.1.21 → 0.1.22

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/Rakefile CHANGED
@@ -3,7 +3,7 @@ require 'rubygems'
3
3
  require 'rake'
4
4
  require 'echoe'
5
5
 
6
- Echoe.new('webs', '0.1.21') do |p|
6
+ Echoe.new('webs', '0.1.22') do |p|
7
7
  p.description = "Reusable webs stuff."
8
8
  p.url = "https://colczak@github.com/websdev/websgem.git"
9
9
  p.author = "Chuck Olczak"
@@ -138,6 +138,15 @@ module Webs
138
138
  def set_fw_params
139
139
  params.merge!( FW_PARAMS ) if defined?( FW_PARAMS )
140
140
  end
141
+
142
+ # NOTE: bots & perl scripts are getting bad format in the request headers
143
+ # generally in the form: :formats=>["charset=iso-8859-1"]
144
+ # Just force those to html
145
+ # ex: https://freewebs.hoptoadapp.com/errors/4334788
146
+ # ex mime type inspection: #<Mime::Type:0x765a7159 @synonyms=[], @string="charset=iso-8859-1", @symbol=nil>
147
+ def fix_request_format
148
+ request.format = :html if request.format.blank? || request.format.to_s =~ /^charset/i
149
+ end
141
150
  end
142
151
  end
143
152
  end
data/lib/webs.rb CHANGED
@@ -7,7 +7,7 @@ require dir + 'helper/params'
7
7
  require dir + 'helper/tags'
8
8
 
9
9
  module Webs
10
- VERSION = '0.1.21'.freeze
10
+ VERSION = '0.1.22'.freeze
11
11
 
12
12
  def self.app_title
13
13
  APP_NAME.titleize
data/webs.gemspec CHANGED
@@ -2,11 +2,11 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = %q{webs}
5
- s.version = "0.1.21"
5
+ s.version = "0.1.22"
6
6
 
7
7
  s.required_rubygems_version = Gem::Requirement.new(">= 1.2") if s.respond_to? :required_rubygems_version=
8
8
  s.authors = ["Chuck Olczak"]
9
- s.date = %q{2011-03-23}
9
+ s.date = %q{2011-03-29}
10
10
  s.description = %q{Reusable webs stuff.}
11
11
  s.email = %q{chuck@webs.com}
12
12
  gemfiles = [
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: webs
3
3
  version: !ruby/object:Gem::Version
4
- hash: 49
4
+ hash: 55
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 1
9
- - 21
10
- version: 0.1.21
9
+ - 22
10
+ version: 0.1.22
11
11
  platform: ruby
12
12
  authors:
13
13
  - Chuck Olczak
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2011-03-23 00:00:00 -04:00
18
+ date: 2011-03-29 00:00:00 -04:00
19
19
  default_executable:
20
20
  dependencies: []
21
21