fix bug in resource history