/* jshint node:true */
'use strict';


// END_POINT = ;
var SETTINGS = {
	scheme: 'http'
};

function determineEndPoint() {
	var result = SETTINGS.scheme + '://127.0.0.1:8080';


	if (process.env.APP_URL) {
		return SETTINGS.scheme + '://' + process.env.APP_URL;
	}

	if (process.env.S3_ENV) {
		result = SETTINGS.scheme + '://' + (process.env.S3_ENV || 'stage') + '.wonderflow.co';
	}
	console.log('END_POINT is', result);
	return result;
}

// TODO: i should do it based on an option of grunt task!!!
module.exports = {
	END_POINT: determineEndPoint()
};