@@ -34,10 +34,10 @@ public class RedumpClient
3434 public bool Debug { get ; set ; } = false ;
3535
3636 /// <summary>
37- /// Maximum retry count for any operation
37+ /// Maximum attempt count for any operation
3838 /// </summary>
3939 /// <remarks>Value has to be greater than 0</remarks>
40- public int RetryCount
40+ public int AttemptCount
4141 {
4242 get ;
4343 set { field = value < 0 ? 3 : value ; }
@@ -141,11 +141,11 @@ public RedumpClient(TimeSpan timeout)
141141#endif
142142
143143 // Attempt to login up as many times as the retry count allows
144- for ( int i = 0 ; i < RetryCount ; i ++ )
144+ for ( int i = 0 ; i < AttemptCount ; i ++ )
145145 {
146146 try
147147 {
148- Console . WriteLine ( $ "Login attempt { i + 1 } of { RetryCount } ") ;
148+ Console . WriteLine ( $ "Login attempt { i + 1 } of { AttemptCount } ") ;
149149
150150 // Get the current token from the login page
151151 var loginPage = await DownloadString ( Constants . LoginUrl ) ;
@@ -200,7 +200,7 @@ public RedumpClient(TimeSpan timeout)
200200 }
201201 }
202202
203- Console . Error . WriteLine ( $ "Could not login to Redump in { RetryCount } attempts, continuing without logging in...") ;
203+ Console . Error . WriteLine ( $ "Could not login to Redump in { AttemptCount } attempts, continuing without logging in...") ;
204204 return false ;
205205 }
206206
@@ -216,14 +216,14 @@ public RedumpClient(TimeSpan timeout)
216216 public async Task < byte [ ] ? > DownloadData ( string uri )
217217 {
218218 // Only retry a positive number of times
219- if ( RetryCount <= 0 )
219+ if ( AttemptCount <= 0 )
220220 return null ;
221221
222- for ( int i = 0 ; i < RetryCount ; i ++ )
222+ for ( int i = 0 ; i < AttemptCount ; i ++ )
223223 {
224224 try
225225 {
226- if ( Debug ) Console . WriteLine ( $ "DEBUG: DownloadData(\" { uri } \" ), Attempt { i + 1 } of { RetryCount } ") ;
226+ if ( Debug ) Console . WriteLine ( $ "DEBUG: DownloadData(\" { uri } \" ), Attempt { i + 1 } of { AttemptCount } ") ;
227227#if NET40
228228 return await Task . Factory . StartNew ( ( ) => _internalClient . DownloadData ( uri ) ) ;
229229#elif NETFRAMEWORK || NETSTANDARD2_0_OR_GREATER
@@ -284,14 +284,14 @@ public RedumpClient(TimeSpan timeout)
284284 public async Task < string ? > DownloadString ( string uri )
285285 {
286286 // Only retry a positive number of times
287- if ( RetryCount <= 0 )
287+ if ( AttemptCount <= 0 )
288288 return null ;
289289
290- for ( int i = 0 ; i < RetryCount ; i ++ )
290+ for ( int i = 0 ; i < AttemptCount ; i ++ )
291291 {
292292 try
293293 {
294- if ( Debug ) Console . WriteLine ( $ "DEBUG: DownloadString(\" { uri } \" ), Attempt { i + 1 } of { RetryCount } ") ;
294+ if ( Debug ) Console . WriteLine ( $ "DEBUG: DownloadString(\" { uri } \" ), Attempt { i + 1 } of { AttemptCount } ") ;
295295#if NET40
296296 return await Task . Factory . StartNew ( ( ) => _internalClient . DownloadString ( uri ) ) ;
297297#elif NETFRAMEWORK || NETSTANDARD2_0_OR_GREATER
0 commit comments