fixes ZEN-13733: fix variable shadowing of endpoints