getCollection e getItem are working both online and offline