This project is archived and is in readonly mode.
patch for action_view/paths PathSet#insert to make sure it applys appropriate cast
Reported by azimux | July 22nd, 2008 @ 08:08 AM | in 2.x
PathSet attempts to make sure that any path it is given to manage is cast to a Path object if it's a string. It's inherited Array#insert will allow you to insert a string into it, causing problems later in reload! (which calls reload! on all it's children, which is defined for paths but not strings.)
This patch makes sure that insert plays by the same rules as [], unshift, and other similar methods. Infact, somebody should find all the mutating methods of Array that accept strings as in put and make sure they are overridden in PathSet to perform casts.
Comments and changes to this ticket
-
josh July 22nd, 2008 @ 04:31 PM
- State changed from new to open
- Assigned user set to josh
-
Repository July 22nd, 2008 @ 05:11 PM
- State changed from open to resolved
(from [2681685450631238511cfc3c2f0fa044c1f8033a]) Extract ActiveSupport::TypedArray class to ensure an array is all of the same type [#673 state:resolved]
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile »
<h2 style="font-size: 14px">Tickets have moved to Github</h2>
The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>