title: The accessible_by call cannot be used with a block 'can' definition
body: <p>It is very interesting that I am not using a block inside can declaration, but I got this error when I open active admin. I've no idea how to fix it.</p>
  <pre class="lang-rb prettyprint-override"><code>[:forename, :surname, :biography, :country].each do |attr_name|
    can :read, User, attr_name,
      id: User.joins(:visibilities)
        .where(visibilities: { level: &quot;public&quot;, attribute_name: attr_name })
        .pluck(:id)
  end
  </code></pre>