fix bug in image element