Update some old codes