fix the bug that caused base baselevel = NULL