5
0
Fork 0
mirror of https://0xacab.org/sutty/sutty synced 2025-02-19 23:01:50 +00:00

BREAKING CHANGE: las colecciones no generan instancias de document

This commit is contained in:
f 2023-10-06 09:56:12 -03:00
parent d601f37045
commit b928fa7bde
No known key found for this signature in database
2 changed files with 10 additions and 10 deletions

View file

@ -43,6 +43,13 @@ class IndexedPost < ApplicationRecord
@full_path ||= File.join(site.path, "_#{locale}", "#{path}.markdown") @full_path ||= File.join(site.path, "_#{locale}", "#{path}.markdown")
end end
# La colección
#
# @return [Jekyll::Collection]
def collection
site.collections[locale.to_s]
end
# Convertir locale a direccionario de PG # Convertir locale a direccionario de PG
# #
# @param [String,Symbol] # @param [String,Symbol]

View file

@ -218,17 +218,10 @@ class Site < ApplicationRecord
jekyll.data jekyll.data
end end
# Traer las colecciones. Todos los artículos van a estar dentro de # Trae las colecciones desde el sitio, sin leer su contenido
# colecciones. #
# @return [Hash]
def collections def collections
unless @read
run_in_path do
jekyll.reader.read_collections
end
@read = true
end
jekyll.collections jekyll.collections
end end