removing extra log function