I appreciate that you detailed how your request might be implemented, even including sample code. Your request reminds me of this solution to a somewhat similar feature request that just involved a configuration change: