Fix db size give an undefined error