Files
kiwistation/nano/scripts/util.coffee
T
Bjorn Neergaard 57a1f6c695 Enable NanoUI to go chromeless
Add a new 'Fancy NanoUI' preference to enable chromeless mode
2015-12-15 13:13:12 -06:00

16 lines
446 B
CoffeeScript

@util =
extend: (first, second) ->
Object.keys(second).forEach (key) ->
secondVal = second[key]
if secondVal and Object::toString.call(secondVal) is "[object Object]"
first[key] = first[key] or {}
util.extend first[key], secondVal
else
first[key] = secondVal
first
href: (url = "", params = {}) ->
url = new Url("byond://#{url}")
util.extend url.query, params
url