5
0
Fork 0
mirror of https://0xacab.org/sutty/sutty synced 2024-11-29 22:06:22 +00:00

feat: encontrar el post a editar desde su indexación #7537

This commit is contained in:
f 2023-10-06 10:04:53 -03:00
parent 6946e86a02
commit ab98119cfe
No known key found for this signature in database

View file

@ -160,7 +160,7 @@ class PostsController < ApplicationController
end
def post
@post ||= site.posts(lang: locale).find(params[:post_id] || params[:id])
@post ||= site.indexed_posts.find_by!(locale: locale, path: params[:post_id] || params[:id]).post
end
# Recuerda el nombre del servicio de subida de archivos