File tree Expand file tree Collapse file tree 1 file changed +6
-16
lines changed
Expand file tree Collapse file tree 1 file changed +6
-16
lines changed Original file line number Diff line number Diff line change @@ -40,12 +40,7 @@ public static String loadFilefromClasspath(final String cssFilename) {
4040 }
4141
4242 private static InputStream readFilefromClasspath (final String cssFilename ) {
43- return java .security .AccessController .doPrivileged (new java .security .PrivilegedAction <InputStream >() {
44- @ Override
45- public InputStream run () {
46- return getClass ().getResourceAsStream (cssFilename );
47- }
48- });
43+ return Util .class .getResourceAsStream (cssFilename );
4944 }
5045
5146 public static String loadCompressedFilefromClasspath (final String cssFilename ) {
@@ -69,16 +64,11 @@ public static String loadCompressedFilefromClasspath(final String cssFilename) {
6964 }
7065
7166 private static InputStream readCompressedFilefromClasspath (final String cssFilename ) {
72- return java .security .AccessController .doPrivileged (new java .security .PrivilegedAction <InputStream >() {
73- @ Override
74- public InputStream run () {
75- try {
76- return new GZIPInputStream (getClass ().getResourceAsStream (cssFilename ), 4096 );
77- } catch (IOException e ) {
78- return null ;
79- }
80- }
81- });
67+ try {
68+ return new GZIPInputStream (Util .class .getResourceAsStream (cssFilename ), 4096 );
69+ } catch (IOException e ) {
70+ throw new IllegalStateException (e );
71+ }
8272 }
8373
8474}
You can’t perform that action at this time.
0 commit comments