lib/cloudcannon-jekyll/generators/collections.rb in cloudcannon-jekyll-4.0.3 vs lib/cloudcannon-jekyll/generators/collections.rb in cloudcannon-jekyll-4.0.4
- old
+ new
@@ -295,10 +295,10 @@
static_pages = @site.static_files.select { |doc| allowed_static_file?(doc) }
pages + static_pages
end
def allowed_document?(doc)
- if !IS_JEKYLL_2_X_X && !IS_JEKYLL_3_04_X && doc.instance_of?(Jekyll::PageWithoutAFile)
+ if Jekyll.const_defined?(:PageWithoutAFile) && doc.instance_of?(Jekyll::PageWithoutAFile)
false
elsif doc.instance_of?(Jekyll::Page)
allowed_page?(doc)
elsif doc.instance_of?(Jekyll::StaticFile)
allowed_static_file?(doc)