few modifications in Collection.php