I had a javaScript function with many nested functions. First I declared all my functions like function funcName() {...js code} and everything was fine. Then I\'ve created a