Skip to content

Instantly share code, notes, and snippets.

@xuorig
Last active June 16, 2017 19:03
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save xuorig/56b197632d5957b17037da40a621b2b0 to your computer and use it in GitHub Desktop.
Save xuorig/56b197632d5957b17037da40a621b2b0 to your computer and use it in GitHub Desktop.
class OnlyFilter
def self.call(schema_member, context)
return true unless visibility_proc = schema_member.metadata[:visibility_proc]
visibility_proc.call(context)
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment