commit
						333b9f5f93
					
				|  | @ -262,11 +262,6 @@ module Jekyll | |||
|           "be removed in 3.0.0. We recommend you switch to Kramdown." | ||||
|       end | ||||
| 
 | ||||
|       if config.key?('paginate') && config['paginate'] && !(config['gems'] || []).include?('jekyll-paginate') | ||||
|         Jekyll::Deprecator.deprecation_message "You appear to have pagination " + | ||||
|           "turned on, but you haven't included the `jekyll-paginate` gem. " + | ||||
|           "Ensure you have `gems: [jekyll-paginate]` in your configuration file." | ||||
|       end | ||||
|       config | ||||
|     end | ||||
| 
 | ||||
|  |  | |||
|  | @ -17,6 +17,7 @@ module Jekyll | |||
|     def conscientious_require | ||||
|       require_plugin_files | ||||
|       require_gems | ||||
|       deprecation_checks | ||||
|     end | ||||
| 
 | ||||
|     # Require each of the gem plugins specified. | ||||
|  | @ -88,5 +89,14 @@ module Jekyll | |||
|       end | ||||
|     end | ||||
| 
 | ||||
|     def deprecation_checks | ||||
|       pagination_included = (site.config['gems'] || []).include?('jekyll-paginate') || defined?(Jekyll::Paginate) | ||||
|       if site.config['paginate'] && !pagination_included | ||||
|         Jekyll::Deprecator.deprecation_message "You appear to have pagination " + | ||||
|           "turned on, but you haven't included the `jekyll-paginate` gem. " + | ||||
|           "Ensure you have `gems: [jekyll-paginate]` in your configuration file." | ||||
|       end | ||||
|     end | ||||
| 
 | ||||
|   end | ||||
| end | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue