Improve checking
Test script working