Fix access to content attribute
This commit is contained in:
parent
47790e7ef1
commit
365ead6b5f
1 changed files with 1 additions and 2 deletions
|
@ -60,8 +60,7 @@ namespace :cloudstorage do
|
||||||
|
|
||||||
[Cerfa, PieceJustificative, Procedure].each { |c|
|
[Cerfa, PieceJustificative, Procedure].each { |c|
|
||||||
c.all.each { |entry|
|
c.all.each { |entry|
|
||||||
content = entry.content
|
content = (c == Procedure)? entry.logo : entry.content
|
||||||
content = entry.logo if c == Procedure
|
|
||||||
unless content.current_path.nil?
|
unless content.current_path.nil?
|
||||||
if File.exist?(File.dirname(content.current_path) + '/uploaded')
|
if File.exist?(File.dirname(content.current_path) + '/uploaded')
|
||||||
previous_filename = File.read(File.dirname(content.current_path) + '/uploaded')
|
previous_filename = File.read(File.dirname(content.current_path) + '/uploaded')
|
||||||
|
|
Loading…
Reference in a new issue