Fixed script logging