public function putToNodeAccess(AccountInterface $account, RouteMatch $route_match) {
    // We'd have 404'd already if node didn't exist, so no need to check.
    // Just hack it out of the route match.
    $node = $route_match->getParameter('node');
    return AccessResult::allowedIf($node->access('update', $account) && $account->hasPermission('create media'));
  }