Uncaught ReferenceError: sfs is not defined

Post here your questions about SFS2X. Here we discuss all server-side matters. For client API questions see the dedicated forums.

Moderators: Lapo, Bax

duylinh013
Posts: 28
Joined: 28 Jul 2016, 01:40

Uncaught ReferenceError: sfs is not defined

Postby duylinh013 » 25 Apr 2017, 08:51

Hi,

I have one problem with sfs html5 client api. Every time the buddies signed in to server and come online, at owner side i got an error "Uncaught ReferenceError: sfs is not defined at SFS2X.Controllers.SystemController._fnSetBuddyVariables (SFS2X_API_JS.js:117)".

Here is the code line 117.

Code: Select all

else if(null!=d)d._setVariables(g),i=sfs.buddyManager.getMyOnlineState();


Thanks,
duylinh013
Posts: 28
Joined: 28 Jul 2016, 01:40

Re: Uncaught ReferenceError: sfs is not defined

Postby duylinh013 » 25 Apr 2017, 09:58

I had changed directly SFS2X_API_JS.js file this code "i=sfs.buddyManager" to "i=this._sfs.buddyManager" and it seems like my app working well again.
User avatar
Bax
Site Admin
Posts: 4610
Joined: 29 Mar 2005, 09:50
Location: Italy
Contact:

Re: Uncaught ReferenceError: sfs is not defined

Postby Bax » 26 Apr 2017, 07:50

Thank you for reporting. We will fix it in the official release version too.
Paolo Bax
The SmartFoxServer Team
User avatar
Bax
Site Admin
Posts: 4610
Joined: 29 Mar 2005, 09:50
Location: Italy
Contact:

Re: Uncaught ReferenceError: sfs is not defined

Postby Bax » 26 Apr 2017, 15:20

We just published an updated version (1.7.1) containing the fix you suggested.
Again, thank you very much.
Paolo Bax
The SmartFoxServer Team

Return to “SFS2X Questions”

Who is online

Users browsing this forum: No registered users and 57 guests