Fixed a bug whereby opening + closing a script file in the same VS session would crash the provider.