carrierwave-postgresql
carrierwave-postgresql copied to clipboard
Content-type not being stored
I may be doing something wrong as I am just getting started with this library but the examples show the identifier being saved as 'file.png' but mine is always a digit '45838' without the extension. Is this a property of OID or did I configure it incorrectly? When I run model.obj.content_type I get nil. Is there something extra I need to do for that to work properly? Either when saving the file or in my uploader class?
What is stored on the model is a pointer ID to the large object in postgres. This gem doesn't make an effort to keep filename or content_type because it just stores the bytes in postgres. If you want to maintain those qualities I would suggest saving them to the model itself.