made some vars const