lib/index.js
function setCurrent (state, type, value) {
  let dest
  if (type === 'file') {
    dest = utils.getRefFilePath(value)
  }

  if (dest) {
    state.current = dest
  }
}
function setCurrent (state, type, value) {
  let dest
  if (type === 'file') {
    dest = utils.getRefFilePath(value)
  }

  if (dest) {
    state.current = dest
  }
}
function setCurrent ( state , type , value ) { let dest if ( type === 'file' ) { dest = utils . getRefFilePath ( value ) } if ( dest ) { state . current = dest } }
Set the current into state
@param {Object} state the state
@param {String} type ref type
@param {String} value ref value
@private
Set the current into state