Fix empty script cases.