fixed bug on null data on State command