You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
74 lines
1.2 KiB
74 lines
1.2 KiB
/*jslint laxbreak:true */
|
|
/*jslint laxcomma:true */
|
|
/*jslint loopfunc:true */
|
|
/*jslint strict:true */
|
|
/*jslint browser:true */
|
|
/*jslint devel:true */
|
|
|
|
// Filename: app.js
|
|
|
|
define([
|
|
"underscore"
|
|
]
|
|
, function (_) {
|
|
"use strict";
|
|
|
|
var Config = {
|
|
debug: false
|
|
, verbose: false
|
|
|
|
, docRoot: "/" // TODO: Should addLeadingSlash instead
|
|
|
|
, daap: {
|
|
hostname: "daap.lalonde.me"
|
|
, protocol: "https"
|
|
, port: 443
|
|
}
|
|
|
|
, player: {
|
|
defaultVolume: 0.5
|
|
}
|
|
|
|
, dev: {
|
|
enabled: true
|
|
|
|
, debug: true
|
|
, verbose: 6
|
|
|
|
, docRoot: "/"
|
|
/*
|
|
, daap: {
|
|
hostname: "daap.localhost"
|
|
, protocol: "http"
|
|
, port: 80
|
|
}
|
|
*/ }
|
|
};
|
|
|
|
/**
|
|
* NOTHING TO EDIT BELOW THIS LINE
|
|
**/
|
|
|
|
if (typeof Config.dev === "object"
|
|
&& typeof Config.dev.enabled !== "undefined"
|
|
&& Config.dev.enabled === true) {
|
|
var devConfig = Config.dev || {}
|
|
;
|
|
|
|
if (Object.size(devConfig) > 0) {
|
|
delete Config.dev;
|
|
|
|
_.extend(Config, devConfig);
|
|
}
|
|
}
|
|
|
|
if ( (typeof Config.debug === "undefined" || Config.debug !== true) && console.debug ) {
|
|
console.debug = function() {};
|
|
}
|
|
|
|
if ( (typeof Config.verbose === "undefined" || Config.verbose <= 5) && console.log ) {
|
|
console.log = function() {};
|
|
}
|
|
|
|
return Config;
|
|
}); |