conditional assignment of :file option was not fully implemented

conditional assignment of :file option was not correctly implemented. 
Still ended up with :file => nil in the hash.