Float == Number Assertion error while using sphinx with nodejs

I am using sphinx for running the following set of queries via nodejs :-

sphClient.SetGeoAnchor("latitude", "longitude", lat, long);
sphClient.SetFilterRange("@geodist",0,1000);
var res = sphClient.Query("@country country_name");

However when i run this it gives me the following error :-

throw new assert.AssertionError({
    ^
AssertionError: "number" == "float"
at SphinxClient.SetGeoAnchor (/node_modules/sphinxapi/lib/sphinxapi.js:395:9)
at Socket.<anonymous> (/node_modules/posts/egx.js:331:15)
at Socket.EventEmitter.emit [as $emit] (events.js:95:17)
at SocketNamespace.handlePacket (/node_modules/socket.io/lib/namespace.js:335:22)
at Manager.onClientMessage (/node_modules/socket.io/lib/manager.js:488:38)
at WebSocket.Transport.onMessage (/node_modules/socket.io/lib/transport.js:387:20)
at Parser.<anonymous> (/node_modules/socket.io/lib/transports/websocket/hybi-16.js:39:10)
at Parser.EventEmitter.emit (events.js:95:17)
at finish (/node_modules/socket.io/lib/transports/websocket/hybi-16.js:288:16)
at Parser.expectHandler (/node_modules/socket.io/lib/transports/websocket/hybi-16.js:299:15)

I even understand what the problem is , after viewing sphinxapi.js , i found out that it compares the typeof(lat) , typeof(long) with "float" , however nodejs returns only "number" . I have tried parseFloat . Also changing the comparison to "number" gives me another error like :-

/node_modules/sphinxapi/lib/sphinxapi.js:79
        l += Number( obj.hasOwnProperty(k) );
                     ^
ReferenceError: obj is not defined
at len (/node_modules/sphinxapi/lib/sphinxapi.js:79:17)
at SphinxClient.AddQuery (/node_modules/sphinxapi/lib/sphinxapi.js:572:6)
at SphinxClient.Query (/node_modules/sphinxapi/lib/sphinxapi.js:476:7)
at Socket.<anonymous> (/node_modules/posts/egx.js:333:25)
at Socket.EventEmitter.emit [as $emit] (events.js:95:17)
at SocketNamespace.handlePacket (/node_modules/socket.io/lib/namespace.js:335:22)
at Manager.onClientMessage (/node_modules/socket.io/lib/manager.js:488:38)
at WebSocket.Transport.onMessage (/node_modules/socket.io/lib/transport.js:387:20)
at Parser.<anonymous> (/node_modules/socket.io/lib/transports/websocket/hybi-16.js:39:10)
at Parser.EventEmitter.emit (events.js:95:17)

javascript has only one type of numbers which is "double". there are no integers, floats, etc. no matter what type of number you are testing, you always get "number" as the result:

typeof 1 is "number"

typeof 1.1 is "number"

i don't know what's going on inside sphinx typeof(), but it is normal that everything's a "number". please post the code or link to where i can find the code. it will help me help you walk through this.