adapt browser.js to support models (and not only collections)

Signed-off-by: Niv Sardi <xaiki@evilgiggle.com>