fix - Storage::Image copy does not create thumbnails
This commit is contained in:
parent
5dddf92543
commit
f749d2d260
3 changed files with 27 additions and 2 deletions
|
|
@ -74,6 +74,26 @@ sub addFileFromCaptcha {
|
|||
return ($filename, $challenge);
|
||||
}
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
|
||||
=head2 copy ( [ storage ] )
|
||||
|
||||
Overriding the copy method so that thumbnail files are copied along with other image files
|
||||
|
||||
=head3 storage
|
||||
|
||||
Optionally pass a storage object to copy the files to.
|
||||
|
||||
=cut
|
||||
|
||||
sub copy {
|
||||
my $self = shift;
|
||||
my $newStorage = shift;
|
||||
# Storage::Image->getFiles excludes thumbnails from the filelist and we want to copy the thumbnails
|
||||
my $filelist = $self->SUPER::getFiles(1);
|
||||
|
||||
return $self->SUPER::copy($newStorage, $filelist);
|
||||
}
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue