Commit 0a348e81 authored by liaozan's avatar liaozan 🏀

Polish

parent e6f5f8b2
package com.schbrain.common.web.utils;
import cn.hutool.core.util.ArrayUtil;
import lombok.extern.slf4j.Slf4j;
import org.springframework.util.Assert;
import org.springframework.util.StreamUtils;
......@@ -58,11 +57,7 @@ public class ContentCachingServletUtils {
return null;
}
}
byte[] content = nativeRequest.getContentAsByteArray();
if (ArrayUtil.isEmpty(content)) {
return null;
}
return new String(content, charset);
return new String(nativeRequest.getContentAsByteArray(), charset);
}
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment