use refresh function