    it "returns only published articles" do
      article = create(:article)
      create(:comment, article: article)
      unpublished_article = create(:article, state: "draft")
      create(:comment, article: unpublished_article)
      expect(described_class.published).to eq([article])
      expect(described_class.bestof).to eq([article])
    end
The software performs an authorization check when an actor attempts to access a resource or perform an action, but it does not correctly perform the check. This allows attackers to bypass intended access restrictions.