fixed a bug in 2.0 upgrade script