removed dead vars, only set entryPath once