Added sync resources functionality