issue #3541 : Fix a bug when loading js from server.
Merge pull request #1465 from SmallAiTT/iss3541_4_testCase

issue #3541 : Fix a bug when loading js from server.