check provder availability first before using it
Merge branch 'fix-#206'