Skip to content

Commit

Permalink
Don't fail if any of the path objects are nil.
Browse files Browse the repository at this point in the history
Fixes #2325
  • Loading branch information
parkr committed May 7, 2014
1 parent 8e5392e commit 8ad4dd3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/jekyll/static_file.rb
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ def initialize(site, base, dir, name)

# Returns source file path.
def path
File.join(@base, @dir, @name)
File.join(*[@base, @dir, @name].compact)
end

# Returns the source file path relative to the site source
Expand All @@ -32,7 +32,7 @@ def relative_path
#
# Returns destination file path.
def destination(dest)
File.join(dest, @dir, @name)
File.join(*[dest, @dir, @name].compact)
end

# Returns last modification time for this file.
Expand Down

0 comments on commit 8ad4dd3

Please sign in to comment.