Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Short-circuit `blank?` on date and time values | Andrew White | 2015-09-21 | 1 | -0/+11 |
| | | | | | | | The concept of a blank date or time doesn't make sense so we can short circuit the calls for `blank?` on these classes to gain small speed boost. Fixes #21657 | ||||
* | File encoding is defaulted to utf-8 in Ruby >= 2.1 | Akira Matsuda | 2015-09-18 | 1 | -2/+0 |
| | |||||
* | docs, make `blank?` behavior clear. Closes #21468. [ci skip] | Yves Senn | 2015-09-02 | 1 | -2/+2 |
| | |||||
* | We tenderized the wrong method! Object#try already had the yield option, ↵ | David Heinemeier Hansson | 2014-08-29 | 1 | -14/+2 |
| | | | | just needed some tenderloving instance_eval to fit the bill | ||||
* | Use instance_eval on @tenderlove's suggestion :trollface: | David Heinemeier Hansson | 2014-08-29 | 1 | -4/+5 |
| | |||||
* | Update examples to show real worth | David Heinemeier Hansson | 2014-08-29 | 1 | -1/+1 |
| | |||||
* | Added yield to Object#presence | David Heinemeier Hansson | 2014-08-29 | 1 | -1/+12 |
| | |||||
* | blank? and present? commit to return singletons [Xavier Noria & Pavel Pravosud] | Xavier Noria | 2013-12-28 | 1 | -18/+42 |
| | | | | | | | | | | | | | | | | | | The contract of blank? and present? was in principle to return Object, as we generally do, the test suite and description was consistent with that, but some examples had comments like "# => true". This cannot be unclear, we either fix the examples, or update the contract. Since users may be already assuming singletons due to the examples and the fact that they were returned before 30ba7ee, the safest option seems to be to revise the contract and the implementation of String#blank? The motivation for 30ba7ee was to improve the performance of the predicate, the refactor based on === is on par regarding speed. With this commit we start documenting return types using YARD conventions. We plan to document return types gradually. | ||||
* | Extracted blank matcher regexp to constant | Paul Nikitochkin | 2013-12-28 | 1 | -1/+3 |
| | |||||
* | Expand double-negative in String#blank? regex | Aman Gupta | 2013-11-20 | 1 | -1/+1 |
| | |||||
* | update some AS code examples to 1.9 hash syntax [ci skip] | Francesco Rodriguez | 2012-09-12 | 1 | -8/+1 |
| | |||||
* | String quotes and trailing spaces | Alexey Gaziev | 2012-04-29 | 1 | -5/+5 |
| | |||||
* | remove unnecessary require core_ext/string/encoding | Sergey Nartimov | 2012-02-14 | 1 | -1/+0 |
| | |||||
* | remove support for ruby 1.8 in AS String extensions | Sergey Nartimov | 2011-12-21 | 1 | -9/+1 |
| | |||||
* | missing require of string/encoding to have access to encoding_aware? | Damien Mathieu | 2011-07-20 | 1 | -0/+1 |
| | |||||
* | fix String#blank? on binary strings. | Damien Mathieu | 2011-07-20 | 1 | -1/+6 |
| | |||||
* | need magic comments | Akira Matsuda | 2011-07-14 | 1 | -0/+2 |
| | |||||
* | treat fullwidth whitespace as a blank character | Akira Matsuda | 2011-07-14 | 1 | -1/+5 |
| | |||||
* | Remove extra white spaces on ActiveSupport docs. | Sebastian Martinez | 2011-05-23 | 1 | -1/+1 |
| | |||||
* | revises comment for blank? method | Vijay Dev | 2011-05-07 | 1 | -3/+3 |
| | |||||
* | Revert "Small edit to the if statement simplification for blank? on the ↵ | Xavier Noria | 2011-05-06 | 1 | -1/+1 |
| | | | | | | | | | | | | | | Object class. An Object doesn't need to be nil and empty to be blank? just one or the other." Reason: the original code is correct, see !nil && !empty -> !(nil || empty) -> !blank That said, this example has too many negations for my linking. Think should be revised to be more positive and straightforward to read. This reverts commit a4b6e3d9be338e93320606f7cb14759b26ced8df. | ||||
* | Small edit to the if statement simplification for blank? on the Object ↵ | Caley Woods | 2011-05-06 | 1 | -1/+1 |
| | | | | class. An Object doesn't need to be nil and empty to be blank? just one or the other. | ||||
* | commit copy-edit: simplifies blank? rdoc and revises formatting | Xavier Noria | 2011-04-19 | 1 | -24/+23 |
| | |||||
* | Revert "Formated docs" | Xavier Noria | 2011-04-19 | 1 | -9/+9 |
| | | | | | | | Reason: "To be blank" and "to be empty" belongs to our everyday terminology, they go in regular font. This reverts commit 280a8709923d2bf707ec4d82ac1e5cb14941da3d. | ||||
* | Formated docs | Sebastian Martinez | 2011-04-18 | 1 | -9/+9 |
| | |||||
* | Formatting docs | Sebastian Martinez | 2011-04-17 | 1 | -10/+10 |
| | |||||
* | Formatting examples | Sebastian Martinez | 2011-04-17 | 1 | -6/+12 |
| | |||||
* | Documented String#blank? | Sebastian Martinez | 2011-04-17 | 1 | -1/+7 |
| | |||||
* | Documented Hash#blank? | Sebastian Martinez | 2011-04-17 | 1 | -1/+6 |
| | |||||
* | Documented Array#blank? | Sebastian Martinez | 2011-04-17 | 1 | -1/+6 |
| | |||||
* | Documented TrueClass#blank? | Sebastian Martinez | 2011-04-17 | 1 | -1/+5 |
| | |||||
* | Documented FalseClass#blank? | Sebastian Martinez | 2011-04-17 | 1 | -1/+5 |
| | |||||
* | Documented NilClass#blank? | Sebastian Martinez | 2011-04-17 | 1 | -1/+5 |
| | |||||
* | copy-edits 108561f | Xavier Noria | 2011-03-05 | 1 | -1/+1 |
| | |||||
* | Adds link to Object.blank? from Object.present? | Jonathon D. Jones | 2011-03-05 | 1 | -1/+1 |
| | |||||
* | Deletes trailing whitespaces (over text files only find * -type f -exec sed ↵ | Santiago Pastorino | 2010-08-14 | 1 | -1/+1 |
| | | | | 's/[ \t]*$//' -i {} \;) | ||||
* | Added Object#presence that returns the object if it's #present? otherwise ↵ | David Heinemeier Hansson | 2009-12-27 | 1 | -2/+20 |
| | | | | returns nil [DHH/Colin Kelley] | ||||
* | blank? and duplicable? are Object extensions | Jeremy Kemper | 2009-03-21 | 1 | -0/+58 |