Fixed some things with resharper