fix chart save bug