A whole bunch of resharper optimizations