diff --git a/src/js/libpannellum.js b/src/js/libpannellum.js
index <HASH>..<HASH> 100644
--- a/src/js/libpannellum.js
+++ b/src/js/libpannellum.js
@@ -985,8 +985,8 @@ function Renderer(container) {
             this.image = new Image();
             this.image.addEventListener('load', function() {
                 processLoadedTexture(self.image, self.texture);
-                releaseTextureImageLoader(self);
                 self.callback(self.texture);
+                releaseTextureImageLoader(self);
             });
         };
Fix multires texture loading artifacts (regression introduced in <I>c6cf<I>f7eb7c1accf<I>ab5fd2e<I>d<I>c<I>).