NoMethodError in Builder::MediapostsController#show

undefined method `title' for nil:NilClass

Extracted source (around line #21):
19
20
21
22
23
24
              
@layout = @page_data['layout']
@post = @page.mediapost_modules.find_by_slug(params[:mediapost_path])
@title = @post.title
end
protected

Rails.root: /app

Application Trace | Framework Trace | Full Trace

Request

Parameters:

{"path"=>"sermons",
 "mediapost_path"=>"the-key-to-contentment-_3-17-19"}

Response

Headers:

None