I have a method that goes through loads of file types like so:
case ".jpg":
res = "image/jpeg";
break;
case ".pdf":
res = "application/pdf";
break;
case ".doc":
res = "application/msword";
break;
..this goes on for a few hundred lines. And I have run into a StyleCop error: SP2101: Method body must not contain more than 120 code lines
I have searched around and can't find anything on this, let alone the suppression. Does anyone know how to suppress this message?
Edit: I think this is a StyleCop+
error and cannot be solved using the FxCop program to copy the suppression.