Can ls in ksh write to output?

I have a ksh script written by someone... now i am trying to modify it to my requirement....

Its executed like this

Read.ksh load ${CUR_MAINT_DATE}

 
if [ "${1}" = "" ]
then
 filnam="Load_CLM"
else
 filnam="${1}"
fi
if [ ! "${2}" = "" ]
then
 CUR_MAINT_DATE="${2}"
fi
if [ -f ${LOG_DIR}/${CUR_MAINT_DATE}/${filnam}_200*log ]
then
  ls ${LOG_DIR}/${CUR_MAINT_DATE}/${filnam}_200*log
  grep 'STEP 00' ${LOG_DIR}/${CUR_MAINT_DATE}/${filnam}_200*log > r.tmp
  date1=`tail -1 r.tmp | cut -f2 -d '[' | cut -f1 -d ']'`
  grep 'Completed at \[' ${LOG_DIR}/${CUR_MAINT_DATE}/${filnam}_200*log > r.tmp
  date2=`tail -1 r.tmp | cut -f2 -d '[' | cut -f1 -d ']'`
  rm -f r.tmp

This code actually writes to a file... when i see in the file i see the value of {LOG_DIR}/${CUR_MAINT_DATE}/${filnam}_200*log
its the location of the log file... now we dont want it and i am not able to figure out what is giving that output...
After putting some echo statements i found that its thai statement thats writing

 
ls ${LOG_DIR}/${CUR_MAINT_DATE}/${filnam}_200*log

I kept echo after every line to see which line is writing... Can anyone say me what i have to do so that it doesnt write the value of ${LOG_DIR}/${CUR_MAINT_DATE}/${filnam}_200*log to output...

Thanks a lot

Thanks a lot for being there for me... I got the solution... i just removes the ls...