function getBackgroundForLayer(layer) {
  log(2, 'Get background for layer: ' + layer.name())
  // By default; check the layers siblings
  var layers = layer.parentGroup() ? layer.parentGroup().layers() : null

  // If it's a group or Artboard; check it's children
  if (layer.isMemberOfClass(MSLayerGroup) || layer.isMemberOfClass(MSArtboardGroup) || layer.isMemberOfClass(MSSymbolMaster) || layer.isMemberOfClass(MSPage)) {
    layers = layer.layers()
  } else if (layer.isMemberOfClass(MSSymbolInstance)) {
    // return backgroundLayerForSymbol(layer)
  }

  return getBGCandidateFromLayers(layers)
}
Get the background layer for a given layer (if any)