Dynamic breakpoints for panels?

while entering page it works. After reload initBreakpoints(); throws error in console