Error while building a new release version

Game development with Board Game Arena Studio
Post Reply
User avatar
tchobello
Posts: 525
Joined: 18 March 2012, 13:19

Error while building a new release version

Post by tchobello »

Hello
I was about to release a new version and I got a JS syntax error :
Line/Column : 2411/13
LineSource : );
Details : syntax error


It was working properly on the local version. What did I miss ?
The error occurs on the penultimate line of this code.

Code: Select all

        notif_killUnderRockfall:function( notif )
		{
			this.confirmationDialog
			( 
				_('Would you like to kill this character ?'), dojo.hitch(this, function()
					{
						this.ajaxcall("/dungeontwister/dungeontwister/killUnderRockfall.html",	
							{ 
								lock: true, 
								character_id: notif.args.character_id
							}, 
							this, function( result ) {}, function( is_error) {} 
						);        
					}
				),
			    dojo.hitch(this, function()
					{
						this.ajaxcall("/dungeontwister/dungeontwister/cancelMove.html", 
							{ 
								lock: true 
							}, 
							this, function( result ) {}, function( is_error) {} 
						);        
					}
				),
            ); 
},
User avatar
eoc
Posts: 105
Joined: 11 January 2017, 20:10

Re: Error while building a new release version

Post by eoc »

The indentation in the last two/three lines seems off. If this is the last defined notification, you're meant to close it with `}` (without the comma in the end).
User avatar
A-dam
Posts: 107
Joined: 28 September 2013, 18:15

Re: Error while building a new release version

Post by A-dam »

eoc wrote: 16 June 2019, 16:22 The indentation in the last two/three lines seems off. If this is the last defined notification, you're meant to close it with `}` (without the comma in the end).
the comma doesn't matter, for me it looks ok, I dont think the problem is in those lines you provide
User avatar
Een
Posts: 3854
Joined: 16 June 2010, 19:52

Re: Error while building a new release version

Post by Een »

Hi,
Probably the comma after the second dojo.hitch argument is not valid for shrinksafe (creates an expectation for a third argument).
http://en.doc.boardgamearena.com/Game_i ... nimization
User avatar
tchobello
Posts: 525
Joined: 18 March 2012, 13:19

Re: Error while building a new release version

Post by tchobello »

Een wrote: 16 June 2019, 21:43 Hi,
Probably the comma after the second dojo.hitch argument is not valid for shrinksafe (creates an expectation for a third argument).
http://en.doc.boardgamearena.com/Game_i ... nimization
Thanks Master.

I suppose first argument is called when you confirm and second argument is called when you decline and that's all.
Post Reply

Return to “Developers”