Added error handling if no current collection is set