Fixed issue when updating DB