code: def _prior_running_states(jid):
      '''
      Return a list of dicts of prior calls to state functions.  This function is
      used to queue state calls so only one is run at a time.
      '''
  
      ret = []
      active = __salt__['saltutil.is_running']('state.*')
      for data in active:
          try:
              data_jid = int(data['jid'])
          except ValueError:
              continue
          if data_jid < int(jid):
              ret.append(data)
      return ref _prior_running_states(jid):
      '''
      Return a list of dicts of prior calls to state functions.  This function is
      used to queue state calls so only one is run at a time.
      '''
  
      ret = []
      active = __salt__['saltutil.is_running']('state.*')
      for data in active:
          try:
              data_jid = int(data['jid'])
          except ValueError:
              continue
          if data_jid < int(jid):
              ret.append(data)
      return ret
docs: Return a list of dicts of prior calls to state functions.  This function is
      used to queue state calls so only one is run at a time.