Skip to content

Commit f8a31c6

Browse files
author
Ignacio Calderon
committed
FIX Gendarme issue with empty strings
1 parent aed88d2 commit f8a31c6

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

DiskCache.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ void Awake ()
7070

7171
public DiskCacheOperation Fetch (Request request)
7272
{
73-
var guid = "";
73+
var guid = string.Empty;
7474
// MD5 is disposable
7575
// http://msdn.microsoft.com/en-us/library/system.security.cryptography.md5.aspx#3
7676
using (System.Security.Cryptography.MD5 md5 = System.Security.Cryptography.MD5.Create ()) {
@@ -98,7 +98,7 @@ IEnumerator DownloadAndSave (Request request, string filename, DiskCacheOperatio
9898
if (request.exception == null && request.response != null) {
9999
if (request.response.status == 200) {
100100
var etag = request.response.GetHeader ("etag");
101-
if (etag != "") {
101+
if (etag != string.Empty) {
102102
File.WriteAllBytes (filename, request.response.bytes);
103103
File.WriteAllText (filename + ".etag", etag);
104104
}

0 commit comments

Comments
 (0)