Skip to content
View pmn4's full-sized avatar

Block or report pmn4

Block user

Prevent this user from interacting with your repositories and sending you notifications. Learn more about blocking users.

You must be logged in to block users.

Maximum 250 characters. Please don’t include any personal information such as legal names or email addresses. Markdown is supported. This note will only be visible to you.
Report abuse

Contact GitHub support about this user’s behavior. Learn more about reporting abuse.

Report abuse

Pinned Loading

  1. tab-cleanup tab-cleanup Public

    Closes tabs w/URLs matching patterns (useful for all those Zoom and Okta tabs that have been opened and are no longer useful)

    JavaScript 2

  2. inflate_has_many.rb inflate_has_many.rb
    1
    module InflateHasMany
    2
      # what #inflate is to `belongs_to` associations, #inflate_has_many is
    3
      # to `has_many` associations
    4
      # see: https://gist.github.com/pmn4/eb497edad63065304383bdfcf8d60b47
    5
      #
  3. Inflate an array of models with a fo... Inflate an array of models with a foreign key relationship in a single query (relationship: Belongs To)
    1
    module InflateBelongsTo
    2
      # when you have an array of models, but want to include (or even map)
    3
      # an associated resource, this method puts together a single query to
    4
      # fetch the data, then appends it to the model, cutting down on total
    5
      # database calls.