changes dan made for me to fix