diff --git a/source/decode.js b/source/decode.js
index <HASH>..<HASH> 100644
--- a/source/decode.js
+++ b/source/decode.js
@@ -129,8 +129,8 @@ var Decode = (function() {
       , int
     ;
 
-    str = str.slice( 0, endIdx )
-    int = str.replace(/i/, '').replace(/e/, '');
+    str = str.slice( 0, endIdx );
+    int = str.match( /\d+/ );
 
     var result = parseInt( int );
changed logic in getInteger for extracting desired part of the string