modification to result script