Commit Graph

18837 Commits

Author SHA1 Message Date
José Valim
3986fcb935 Initialize sid should just skip instance variables. 2010-10-04 08:47:36 +02:00
Aaron Patterson
69a2c6b041 converting inject([]) to map 2010-10-03 16:42:08 -07:00
Aaron Patterson
365c93b7cd speed up duplicate migration detection 2010-10-03 16:39:48 -07:00
Aaron Patterson
40761c4bf3 reduce the number of calls to camelize 2010-10-03 16:36:43 -07:00
Aaron Patterson
e6583901e5 convertion MigrationProxy to a Struct, initialize instance variables 2010-10-03 16:32:27 -07:00
Aaron Patterson
341e71a1b9 dry up some migration logic 2010-10-03 16:23:07 -07:00
Aaron Patterson
8beda11fd3 no need to differentiate between nil and false in this case 2010-10-03 16:13:45 -07:00
Aaron Patterson
a6c42c8267 two argument String#slice is faster than single argument, also avoid creating a Range object 2010-10-03 15:38:17 -07:00
Aaron Patterson
5154a464cc lengths will be nil or an array 2010-10-03 15:35:56 -07:00
Aaron Patterson
7836616a64 remove a few function calls 2010-10-03 15:18:32 -07:00
Aaron Patterson
bd78d24bd8 be kind to the garbage collector and reuse our visitor object 2010-10-03 14:40:06 -07:00
Aaron Patterson
83633b807a avoid creating objects when we can 2010-10-03 14:40:06 -07:00
Aaron Patterson
18a7b767e8 moving fake model to the correct file 2010-10-03 14:40:06 -07:00
Piotr Sarnacki
adfd43a4da Add documentation on app_generators 2010-10-03 23:32:03 +02:00
José Valim
5f292c9441 Merge branch 'racksession' 2010-10-03 21:48:32 +02:00
José Valim
653acac069 Solve some warnings and a failing test. 2010-10-03 21:45:30 +02:00
José Valim
74dd8a3681 Move ETag and ConditionalGet logic from AD::Response to the middleware stack. 2010-10-03 21:25:22 +02:00
José Valim
50215f9525 Rely on Rack::Session stores API for more compatibility across the Ruby world. 2010-10-03 21:24:22 +02:00
Santiago Pastorino
5836af8f8b PERF: more Hash + map changes 2010-10-03 16:33:46 -02:00
Santiago Pastorino
42fad8c82b PERF: more changes from inject({}) to Hash + map 2010-10-03 15:03:59 -02:00
Santiago Pastorino
4920312643 PERF: Don't create unnecessary objects 2010-10-03 14:58:23 -02:00
Santiago Pastorino
10249d7b77 PERF: change inject({}) with Hash + map 2010-10-03 14:52:46 -02:00
Santiago Pastorino
c28bebef13 PERF: Hash[] + map is faster than this silly inject, and var[1..-1] is faster than var.sub('@', '') 2010-10-03 13:34:34 -02:00
David Chelimsky
f656796d05 Rename _assigns to view_assigns in AV::TC
- also add tests
- also deprecate _assigns

[#5751 state:resolved]

Signed-off-by: Santiago Pastorino <santiago@wyeworks.com>
2010-10-03 13:30:31 -02:00
José Valim
49cc01002e Be more explicit about what is deprecated. 2010-10-02 09:40:54 -07:00
José Valim
04cbabb0a0 Deprecate generators in Railties. You should use app_generators instead. 2010-10-02 18:38:23 +02:00
José Valim
757bbd540c :'' is not valid ruby. 2010-10-02 18:30:38 +02:00
Aditya Sanghi
297cf0b266 added test for form_for with search_field
Signed-off-by: José Valim <jose.valim@gmail.com>
2010-10-02 17:48:12 +02:00
Aditya Sanghi
8d1df887d3 Fixing search_field to remove object attribute from options hash [#5730 state:resolved]
Signed-off-by: José Valim <jose.valim@gmail.com>
2010-10-02 17:48:11 +02:00
José Valim
7b0c592e38 reload_routes! is part of the public API and should not be removed. 2010-10-02 17:45:26 +02:00
José Valim
609849a0f1 Fix a routing test. Reorganize middleware tests. 2010-10-02 17:42:36 +02:00
Carlos Antonio da Silva
4e93179ed3 Refactor AssociationCollection#include? with objects in memory
Signed-off-by: José Valim <jose.valim@gmail.com>
2010-10-02 08:40:38 +02:00
José Valim
b951522018 Revert "Perf: refactor _assign method to avoid inject and defining unneeded local var."
_assigns must return a hash.

This reverts commit e66c1cee86.
2010-10-02 08:36:55 +02:00
Aaron Patterson
3eb7f9adee removing more duplicate code. :'( 2010-10-01 18:09:37 -07:00
Aaron Patterson
50cf5c11a1 fixing warnings with regexps on assert_match 2010-10-01 18:07:19 -07:00
Aaron Patterson
ffbcb84c21 removing more duplicate code 2010-10-01 18:05:59 -07:00
Aaron Patterson
44f85678e9 delete repeated code 2010-10-01 18:01:34 -07:00
Aaron Patterson
6e1df2ca46 remove another lolinject 2010-10-01 17:55:39 -07:00
Aaron Patterson
dfa331ae15 use a method that actually exists 2010-10-01 17:54:50 -07:00
Aaron Patterson
61e8b23fe5 speed up index_by by removing a lolinject 2010-10-01 17:37:34 -07:00
Aaron Patterson
ff2fdcc52b removing AS::Testing::Default in favor of just undefing default_test 2010-10-01 17:22:42 -07:00
Xavier Noria
542ddd8c89 brings csrf_meta_tags back to the generated layout
After more discussion, it has be agreed that this kind
of changes within reasonable margins are OK for 3.1.
That is, it is fine to change a little bit the generators
even if that means examples in existing books won't be
exact. (Note that the singular csrf_meta_tag exists as an
alias and thus those outdated examples will run, same for
existing applications.)
2010-10-02 00:10:32 +02:00
Aaron Patterson
45edeed1ee Arel::Sql::Engine.new does not do anything anymore 2010-09-30 16:28:12 -07:00
Aaron Patterson
0238228e5d type_name should check for blank because people may have messed up databases 2010-09-30 16:03:05 -07:00
Aaron Patterson
15419a5dc6 build_where should be private 2010-09-30 14:37:09 -07:00
Aaron Patterson
fb4ee9c7e5 type_name is never a blank string, so use faster .nil? call 2010-09-30 14:37:04 -07:00
Marcelo Giorgi
ef6df93a8d AssociationCollection#include? working properly for objects added with build method [#3472 state:resolved] 2010-09-30 12:13:52 -07:00
Aaron Patterson
505b532605 speeding up object instantiation by eliminating instance_eval 2010-09-30 12:13:12 -07:00
Aaron Patterson
ef8ce78ba1 changing map and include to find 2010-09-30 11:00:14 -07:00
Aaron Patterson
a8a62f87f6 [#5441 state:resolved] refactoring code to determine aggregate column 2010-09-30 10:17:38 -07:00