Closed mroliveira7 closed 5 years ago
@mroliveira7 I'm not sure why it isn't working. My assumption is that the ActiveStorage::Blob
instance has an extract-able file path that is overriding the keyword arg.
You might try storing the raw image data in a different object, the copied code below is from the test suite and may work if adapted.
#
im_data = StringIO.new(IO.binread(@image_fixtures.join('clone.jpg')))
trooper = Sablon.content(:image, im_data, filename: 'clone.jpg', properties: {height: '1cm', width: '4cm'})
Ok, i'll try that. Thanks! :+1:
Closing issue, assuming the suggested fix above worked.
Hello, i'm testing this gem to check whether i'm gonna add it to a project i'm working on but i'm having some issues with images. The filename does not contain the extension of the file so i added the filename on the Sablon.content method. I'm on Rails 6.0 and ruby 2.6.3
Here is the code:
I'm receiving an error
Filename: '9o2a0zxg5cvgoxj34g047ytjwits' has no discernable extension
It looks like the filename that i added when calling Sablo.content is not working Did i miss something?