fixed unused vars