added protection to scripts without arguments