Add updateimage method and source clean.