@@ -142,7 +142,7 @@ public class AWSIotMqttManager {
142142 */
143143 private int currentReconnectRetryTime ;
144144 /** Maximum number of automatic reconnect attempts done before giving up. */
145- private int maxAutoReconnectAttepts ;
145+ private int maxAutoReconnectAttempts ;
146146 /** Reconnects attempted so far. */
147147 private int autoReconnectsAttempted ;
148148 /** Is offline publish queueing enabled? */
@@ -268,7 +268,7 @@ public int getMaxReconnectRetryTime() {
268268 * @return number of reconnects to automatically attempt. Retry forever = -1.
269269 */
270270 public int getMaxAutoReconnectAttempts () {
271- return maxAutoReconnectAttepts ;
271+ return maxAutoReconnectAttempts ;
272272 }
273273
274274 /**
@@ -277,11 +277,11 @@ public int getMaxAutoReconnectAttempts() {
277277 * @param attempts number of reconnects attempted automatically. Retry
278278 * forever = -1.
279279 */
280- public void setMaxAutoReconnectAttepts (int attempts ) {
280+ public void setMaxAutoReconnectAttempts (int attempts ) {
281281 if (attempts <= 0 && attempts != -1 ) {
282282 throw new IllegalArgumentException ("Max reconnection attempts must be postive or -1" );
283283 }
284- maxAutoReconnectAttepts = attempts ;
284+ maxAutoReconnectAttempts = attempts ;
285285 }
286286
287287 /**
@@ -552,7 +552,7 @@ private void initDefaults() {
552552 autoReconnect = DEFAULT_AUTO_RECONNECT_ENABLED ;
553553 minReconnectRetryTime = DEFAULT_MIN_RECONNECT_RETRY_TIME_SECONDS ;
554554 maxReconnectRetryTime = DEFAULT_MAX_RECONNECT_RETRY_TIME_SECONDS ;
555- maxAutoReconnectAttepts = DEFAULT_AUTO_RECONNECT_ATTEMPTS ;
555+ maxAutoReconnectAttempts = DEFAULT_AUTO_RECONNECT_ATTEMPTS ;
556556 userKeepAlive = DEFAULT_KEEP_ALIVE_SECONDS ;
557557 mqttLWT = null ;
558558 offlinePublishQueueEnabled = DEFAULT_OFFLINE_PUBLISH_QUEUE_ENABLED ;
@@ -895,7 +895,7 @@ public void onFailure(IMqttToken asyncActionToken, Throwable e) {
895895 */
896896 boolean scheduleReconnect () {
897897 // schedule a reconnect if unlimited or if we haven't yet hit the limit
898- if (maxAutoReconnectAttepts == -1 || autoReconnectsAttempted < maxAutoReconnectAttepts ) {
898+ if (maxAutoReconnectAttempts == -1 || autoReconnectsAttempted < maxAutoReconnectAttempts ) {
899899
900900 (new Handler (Looper .getMainLooper ())).postDelayed (new Runnable () {
901901 @ Override
0 commit comments