Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | remove nil in NullType#ref. | Angelo capilleri | 2013-12-04 | 1 | -3/+1 |
| | | | | | Return Nil is implicit in a method and this syntax is used in the others classes | ||||
* | Convert Mime::NullType in a singleton | Guillermo Iguaran | 2013-12-03 | 1 | -1/+4 |
| | |||||
* | Remove deprecated cattr_* requires | Genadi Samokovarov | 2013-12-03 | 1 | -1/+1 |
| | |||||
* | Fix undefined method `ref' for nil:NilClass for bad accept headers | Stephen Becker IV | 2013-06-19 | 1 | -1/+1 |
| | |||||
* | Remove Mime::Type#verify_request? and Mime::Type.browser_generated_types ↵ | kennyj | 2013-06-02 | 1 | -16/+0 |
| | | | | were deprecated. | ||||
* | Return nil for Mime::NullType#ref | Andrew White | 2013-04-10 | 1 | -0/+4 |
| | |||||
* | Reverts rendering behavior when format is unknown | Grzegorz Świrski | 2013-04-10 | 1 | -1/+5 |
| | | | | | | | | | If a request has unknown format (eg. /foo.bar), the renderer fallbacks to default format. This patch reverts Rails 3.2 behavior after c2267db commit. Fixes issue #9654. | ||||
* | Mark unused variables and make some style fixes | Agis Anastasopoulos | 2013-04-08 | 1 | -2/+2 |
| | | | | It'd be a nice convention to mark the unused variables like this, now that Ruby 2 will issue no warnings for such vars being unused. | ||||
* | return Mime::NullType if format is unknown | Angelo Capilleri | 2012-12-22 | 1 | -1/+12 |
| | | | | | | | | | | If a request has an unknown format, the methods html?, xml?, json? ...etc not raise an Exception. This patch add a class Mime::NullType, that is returned when request.format is unknown and it responds false to the methods that ends with '?' and true to 'nil?'. It refers to #7837, this issue is considered a improvement not a bug. | ||||
* | implement to_a and to_ary so that the Array() call in template.rb will | Aaron Patterson | 2012-11-09 | 1 | -9/+14 |
| | | | | | | | | | | | | | | | | not raise so many exceptions: https://github.com/rails/rails/blob/master/actionpack/lib/action_view/template.rb#L126 irb(main):001:0> class Foo; def method_missing(*args); super; end end => nil irb(main):002:0> $DEBUG = true => true irb(main):003:0> Array(Foo.new) Exception `NoMethodError' at (irb):1 - undefined method `to_ary' for #<Foo:0x007f854390e488> Exception `NoMethodError' at (irb):1 - undefined method `to_a' for #<Foo:0x007f854390e488> => [#<Foo:0x007f854390e488>] irb(main):004:0> | ||||
* | 1.9 hash syntax changes to docs | AvnerCohen | 2012-10-31 | 1 | -2/+2 |
| | |||||
* | depreacte unused Mime::Type#verify_request? and ↵ | grosser | 2012-09-24 | 1 | -1/+6 |
| | | | | Mime::Type.browser_generated_types | ||||
* | Fixed missing require | Ilya Vorontsov | 2012-09-08 | 1 | -0/+1 |
| | | | | | | | Missing require caused fail of guide generation (in action_dispatch/http/mime_type, line 295, undefined method `ends_with` for "to_ary":String) With this fix guides were normally generated | ||||
* | Refactor `Mime::Type` | Aleksey Magusev | 2012-09-05 | 1 | -84/+93 |
| | | | | | | | | | | | `parse` method performance improvements - ~27-33%: accept = "image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, application/x-shockwave-flash, application/vnd.ms-excel, application/vnd.ms-powerpoint, application/msword, , pronto/1.00.00, sslvpn/1.00.00.00, */*" Benchmark.measure{ 1_000_0.times { Mime::Type.parse(accept) }} old: 1.430000 0.000000 1.430000 ( 1.440977) new: 0.920000 0.000000 0.920000 ( 0.921813) | ||||
* | load active_support/core_ext/object/blank in active_support/rails | Xavier Noria | 2012-08-02 | 1 | -1/+0 |
| | |||||
* | Prevent conflict between mime types and Object methods | Mircea Pricop | 2012-07-06 | 1 | -1/+12 |
| | | | | | | | | | | | | | | | | | | | | | | | Assuming the type ":touch", Collector.new was calling send(:touch), which instead of triggering method_missing and generating a new collector method, actually invoked the private method `touch` inherited from Object. By generating the method for each mime type as it is registered, the private methods on Object can never be reached by `send`, because the `Collector` will have them before `send` is called on it. To do this, a callback mechanism was added to Mime::Type This allows someone to add a callback for whenever a new mime type is registered. The callback then gets called with the new mime as a parameter. This is then used in AbstractController::Collector to generate new collector methods after each mime is registered. | ||||
* | add Mime.fetch so we can have default mime types | Aaron Patterson | 2012-07-03 | 1 | -0/+5 |
| | |||||
* | both string and sumbol will be interpolated as string no need to convert to_s | ganesh | 2012-06-11 | 1 | -3/+3 |
| | |||||
* | Fix rdoc formatting in Mime::Type | Mark Rushakoff | 2012-04-29 | 1 | -5/+5 |
| | |||||
* | Fix example action dispatch in mime type | Alexey Vakhov | 2012-04-07 | 1 | -1/+1 |
| | |||||
* | Added parsing of arbitrary media type parameters. | Steve Klabnik | 2012-03-05 | 1 | -3/+3 |
| | | | | | | Based on #4918. Related to #4127. | ||||
* | Correctly handle single media with q value. Fixes #736. | Scott W. Bradley | 2012-02-06 | 1 | -1/+3 |
| | |||||
* | Allow symbols to be passed for extension aliases | Justin Campbell | 2011-12-17 | 1 | -1/+1 |
| | |||||
* | Implement Mime::Type#respond_to? (consistently with #method_missing) | Evgeniy Dolzhenko | 2011-09-25 | 1 | -0/+4 |
| | |||||
* | Remove extra white spaces on ActionPack docs. | Sebastian Martinez | 2011-05-23 | 1 | -2/+2 |
| | |||||
* | Use Mime::Type references. | José Valim | 2011-02-08 | 1 | -1/+5 |
| | |||||
* | Merge branch 'master' of git://github.com/lifo/docrails | Xavier Noria | 2010-12-05 | 1 | -2/+2 |
|\ | |||||
| * | Fix mime type doc typos | Carlos Antonio da Silva | 2010-12-04 | 1 | -2/+2 |
| | | |||||
* | | Fix tests on 1.9.2. | José Valim | 2010-11-28 | 1 | -6/+9 |
| | | |||||
* | | trailing star mimes should respect the order in which mime types are defined. | José Valim | 2010-11-28 | 1 | -7/+11 |
|/ | |||||
* | process text/* if it appears in the middle of | Neeraj Singh | 2010-11-25 | 1 | -1/+5 |
| | | | | HTTP_ACCEPT parameter | ||||
* | processing image/* is an odditity because there is | Neeraj Singh | 2010-11-25 | 1 | -1/+1 |
| | | | | | | a test case which expects image/* to not to be expanded. So I am leaving image/* as it is and process only text/* and application/* | ||||
* | unregister method implementation and test | Neeraj Singh | 2010-11-25 | 1 | -0/+12 |
| | |||||
* | remove select, collect and then inject with | Neeraj Singh | 2010-11-22 | 1 | -1/+1 |
| | | | | | | something better Signed-off-by: José Valim <jose.valim@gmail.com> | ||||
* | string include method is 10x faster than creating | Neeraj Singh | 2010-11-22 | 1 | -1/+1 |
| | | | | | | a new regex object every single time Signed-off-by: José Valim <jose.valim@gmail.com> | ||||
* | Compile regex only once | Neeraj Singh | 2010-11-22 | 1 | -3/+5 |
| | | | | Signed-off-by: José Valim <jose.valim@gmail.com> | ||||
* | implement code that handles text/*, appplication/*, | Neeraj Singh | 2010-11-22 | 1 | -1/+16 |
| | | | | | | and image/* Signed-off-by: José Valim <jose.valim@gmail.com> | ||||
* | Deletes trailing whitespaces (over text files only find * -type f -exec sed ↵ | Santiago Pastorino | 2010-08-14 | 1 | -10/+10 |
| | | | | 's/[ \t]*$//' -i {} \;) | ||||
* | Fix a bunch of minor spelling mistakes | Evgeniy Dolzhenko | 2010-06-11 | 1 | -1/+1 |
| | |||||
* | adds missing requires for Object#blank? and Object#present? | Xavier Noria | 2010-03-28 | 1 | -0/+1 |
| | |||||
* | Clean up Mime::Type and remove deprecated stuff (from 2.3). | José Valim | 2010-03-20 | 1 | -7/+1 |
| | |||||
* | Make sure evalled method knows where it came from | Yehuda Katz | 2009-12-29 | 1 | -2/+2 |
| | |||||
* | Silence some trivial warnings: shadowed local vars, indentation mismatches | Jeremy Kemper | 2009-12-28 | 1 | -1/+1 |
| | |||||
* | Reduce TextTemplate cost for simple cases | Yehuda Katz | 2009-10-28 | 1 | -0/+1 |
| | |||||
* | Avoid super in define_method for Rubinius | Yehuda Katz | 2009-10-09 | 1 | -1/+6 |
| | |||||
* | Remove last TODO. | José Valim | 2009-07-29 | 1 | -1/+1 |
| | | | | Signed-off-by: Yehuda Katz <wycats@gmail.com> | ||||
* | Small changes to get 1.9 passing (for the most part) | Yehuda Katz | 2009-06-23 | 1 | -1/+1 |
| | |||||
* | Fixing pending tests and fixed some formats / partial rendering semantics | Yehuda Katz + Carl Lerche | 2009-06-17 | 1 | -1/+13 |
| | |||||
* | Remove some response content type concepts from ActionView | Yehuda Katz + Carl Lerche | 2009-05-21 | 1 | -1/+1 |
| | |||||
* | Cherry-pick core extensions | Jeremy Kemper | 2009-05-13 | 1 | -0/+1 |
| |