Is it? Well that method is is already an extraction - https://github.com/strzalek/rails/blob/a5c609f1290f2ca071f8980eb08f3529513bbdee/actionview/lib/action_view/template/resolver.rb#L231

Extracting this small pice of code won't be beneficial in any way in my opinion. What do you think?