You don't need to use this.curFolder (or store it at all).  You can pass "this.header" for the first argument and null for the second and it will do the same thing.  Please remove the passing of folder/curFolder.