@@ -108,10 +108,12 @@ protected function _thumbnailImage(ImageWithImagineInterface $image, ImagePathIn
108
108
109
109
/** @var IImage $animated */
110
110
$ animated = null ;
111
+ $ options = null ;
111
112
$ imagine = $ image ->getImagine ();
112
113
if ($ this ->handleAnimatedGif ($ image , function (IImage $ iimage ) use ($ imagine , $ size , &$ animated , $ image ) {
113
114
$ animated = $ imagine ->create ($ size );
114
115
$ animated ->layers ()->remove (0 );
116
+ $ image ->setImagineImage ($ animated );
115
117
// we take first frame conf
116
118
/** @var IImage $iframe */
117
119
$ iframe = $ iimage ->layers ()[0 ];
@@ -121,14 +123,13 @@ protected function _thumbnailImage(ImageWithImagineInterface $image, ImagePathIn
121
123
'animated.delay ' => $ iframe ->getImagick ()->getImageDelay () * 10 ,
122
124
'animated.loop ' => $ iframe ->getImagick ()->getImageIterations (),
123
125
];
124
- // put those options for next binary dump only
125
126
$ image ->setEphemeralImagineOptions ($ options );
126
127
}, function (IImage $ iframe ) use ($ size , $ mode , &$ animated ) {
127
128
$ animated ->layers ()->add ($ iframe ->thumbnail ($ size , $ mode ));
128
129
}, function (IImage $ iimage ) {
129
130
// nothing
130
131
})) {
131
- $ image -> setImagineImage ( $ animated );
132
+ // nothing
132
133
return true ;
133
134
}
134
135
$ image ->setImagineImage ($ image ->getImagineImage ()->thumbnail ($ size , $ mode ));
0 commit comments