fix that nullpoint but adding more log