Fixed some logic and added error message if file given is not .vsx