This repository has been archived by the owner. It is now read-only.

nil param value that expects a hash should return :key => nil #20

Closed
wants to merge 4 commits into
from
Commits on Apr 9, 2012
  1. When a nil param value arrives in place of an expected hash, return

    bjhess committed Apr 9, 2012
    :key => nil, not simply nil.
    
    Prior:
    
    (rdb:1) params
    {"book"=>nil}
    (rdb:1) params.permit(book: { genre: :type })
    nil
    
    Now:
    
    (rdb:1) params
    {"book"=>nil}
    (rdb:1) params.permit(book: { genre: :type })
    {"book"=>nil}
  2. When a nil param value arrives in place of an expected hash, return

    bjhess committed Apr 9, 2012
    :key => nil, not simply nil.
    
    Prior:
    
    (rdb:1) params
    {"book"=>nil}
    (rdb:1) params.permit(book: { genre: :type })
    nil
    
    Now:
    
    (rdb:1) params
    {"book"=>nil}
    (rdb:1) params.permit(book: { genre: :type })
    {"book"=>nil}
Commits on Apr 17, 2012
Commits on May 14, 2012