Added auto sync functionality

Sorry if this breaks shit