Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
paperclip
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ikcrm_common
paperclip
Commits
9908421d
Commit
9908421d
authored
Dec 30, 2008
by
Jon Yurek
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Logging can be turned off.
parent
211e9883
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
2 deletions
+9
-2
lib/paperclip.rb
+4
-1
lib/paperclip/attachment.rb
+5
-1
No files found.
lib/paperclip.rb
View file @
9908421d
...
@@ -49,6 +49,8 @@ module Paperclip
...
@@ -49,6 +49,8 @@ module Paperclip
# Provides configurability to Paperclip. There are a number of options available, such as:
# Provides configurability to Paperclip. There are a number of options available, such as:
# * whiny_thumbnails: Will raise an error if Paperclip cannot process thumbnails of
# * whiny_thumbnails: Will raise an error if Paperclip cannot process thumbnails of
# an uploaded image. Defaults to true.
# an uploaded image. Defaults to true.
# * log: Logs progress to the Rails log. Uses ActiveRecord's logger, so honors
# log levels, etc. Defaults to true.
# * command_path: Defines the path at which to find the command line
# * command_path: Defines the path at which to find the command line
# programs if they are not visible to Rails the system's search path. Defaults to
# programs if they are not visible to Rails the system's search path. Defaults to
# nil, which uses the first executable found in the user's search path.
# nil, which uses the first executable found in the user's search path.
...
@@ -57,7 +59,8 @@ module Paperclip
...
@@ -57,7 +59,8 @@ module Paperclip
@options
||=
{
@options
||=
{
:whiny_thumbnails
=>
true
,
:whiny_thumbnails
=>
true
,
:image_magick_path
=>
nil
,
:image_magick_path
=>
nil
,
:command_path
=>
nil
:command_path
=>
nil
,
:log
=>
true
}
}
end
end
...
...
lib/paperclip/attachment.rb
View file @
9908421d
...
@@ -256,7 +256,11 @@ module Paperclip
...
@@ -256,7 +256,11 @@ module Paperclip
end
end
def
log
message
def
log
message
logger
.
info
(
"[paperclip]
#{
message
}
"
)
logger
.
info
(
"[paperclip]
#{
message
}
"
)
if
logging?
end
def
logging?
Paperclip
.
options
[
:log
]
end
end
def
valid_assignment?
file
#:nodoc:
def
valid_assignment?
file
#:nodoc:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment