Skip to content

undefined method `enriched?' for #<Hash:0x000000069cebf8> #74

@yo-gen

Description

@yo-gen

I have following code in my controller and views respectively. The feed is returned correctly in the controller. But template rendering throws this error.
undefined method `enriched?' for #Hash:0x000000069cebf8
Anyone has any idea?

class NotificationsController < ApplicationController
  before_action :authenticate_user!

  def index
  	@enricher = StreamRails::Enrich.new
	@feed = StreamRails.feed_manager.get_notification_feed(current_user.id)
	@results = @feed.get()['results']
	@activities = @enricher.enrich_activities(@results)
  end

end

Following is the view code

<div class="container">
    <div class="container-pins">
    	<% byebug %>
      <% for activity in @activities %>
          <%= render_activity activity %>
      <% end %>
    </div>
</div>

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions