add check for PREVIEW_MODE
add check for cimproviders
add check for icap
improved the check patches script