id stringlengths 34 124 | type stringclasses 4
values | prompt stringlengths 0 4.95k | response stringlengths 21 4.89k | source_lang stringclasses 3
values | target_lang stringclasses 2
values | repo stringclasses 75
values | path stringlengths 10 88 | license stringclasses 1
value | commit stringlengths 40 40 | stars int64 431 18.7k | source_url stringlengths 86 176 | line_start int64 1 214 | line_end int64 3 253 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
ExpediaGroup/cyclotron:cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee:5:raw_corpus | raw_corpus | $scope.$watchCollection 'currentPage', (currentPage) ->
return unless currentPage?.length > 0
calculateOverrides()
$scope.$watch 'dashboardOverrides', (dashboardOverrides) ->
return unless dashboardOverrides?
calculateOverrides()
,... | CoffeeScript | ExpediaGroup/cyclotron | cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | MIT | 0228db71d84a3138a9ffddb50d8f4f8ff37cc5ab | 1,544 | https://github.com/ExpediaGroup/cyclotron/blob/0228db71d84a3138a9ffddb50d8f4f8ff37cc5ab/cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | 139 | 148 | ||
ExpediaGroup/cyclotron:cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee:5:completion | completion | $scope.$watchCollection 'currentPage', (currentPage) ->
return unless currentPage?.length > 0
calculateOverrides()
$scope.$watch 'dashboardOverrides', (dashboardOverrides) -> | return unless dashboardOverrides?
calculateOverrides()
, true
} | CoffeeScript | CoffeeScript | ExpediaGroup/cyclotron | cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | MIT | 0228db71d84a3138a9ffddb50d8f4f8ff37cc5ab | 1,544 | https://github.com/ExpediaGroup/cyclotron/blob/0228db71d84a3138a9ffddb50d8f4f8ff37cc5ab/cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | 139 | 148 |
ExpediaGroup/cyclotron:cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee:1:raw_corpus | raw_corpus | ###
# Copyright (c) 2013-2016 the original author or authors.
#
# Licensed under the MIT License (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.opensource.org/licenses/mit-license.php
#
# Unless required by applicable law ... | CoffeeScript | ExpediaGroup/cyclotron | cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | MIT | df26fc48ea0296697e2755b7a1d9ce5cf50a4483 | 1,544 | https://github.com/ExpediaGroup/cyclotron/blob/df26fc48ea0296697e2755b7a1d9ce5cf50a4483/cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | 1 | 50 | ||
ExpediaGroup/cyclotron:cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee:1:completion | completion | ###
# Copyright (c) 2013-2016 the original author or authors.
#
# Licensed under the MIT License (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.opensource.org/licenses/mit-license.php
#
# Unless required by applicable law ... | scope.sidebarContent[0].isOpen = true
else
scope.isShowHideWidgetsOpen = true
$element = $(element)
$parent = $element.parent()
$header = $element.find '.sidebar-header'
$accordion = $element.find '.sidebar-accordion'
$footer = $el... | CoffeeScript | CoffeeScript | ExpediaGroup/cyclotron | cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | MIT | df26fc48ea0296697e2755b7a1d9ce5cf50a4483 | 1,544 | https://github.com/ExpediaGroup/cyclotron/blob/df26fc48ea0296697e2755b7a1d9ce5cf50a4483/cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | 1 | 50 |
ExpediaGroup/cyclotron:cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee:1:raw_corpus | raw_corpus | ###
# Copyright (c) 2013-2016 the original author or authors.
#
# Licensed under the MIT License (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.opensource.org/licenses/mit-license.php
#
# Unless required by applicable law ... | CoffeeScript | ExpediaGroup/cyclotron | cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | MIT | d9f6710d26e1473dc1dab805685dd5b572fead4a | 1,544 | https://github.com/ExpediaGroup/cyclotron/blob/d9f6710d26e1473dc1dab805685dd5b572fead4a/cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | 1 | 46 | ||
ExpediaGroup/cyclotron:cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee:1:completion | completion | ###
# Copyright (c) 2013-2016 the original author or authors.
#
# Licensed under the MIT License (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.opensource.org/licenses/mit-license.php
#
# Unless required by applicable law ... | $element = $(element)
$parent = $element.parent()
$header = $element.find '.sidebar-header'
$accordion = $element.find '.sidebar-accordion'
$footer = $element.find '.sidebar-footer'
$hitbox = $element.find '.sidebar-expander-hitbox'
$expander = $el... | CoffeeScript | CoffeeScript | ExpediaGroup/cyclotron | cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | MIT | d9f6710d26e1473dc1dab805685dd5b572fead4a | 1,544 | https://github.com/ExpediaGroup/cyclotron/blob/d9f6710d26e1473dc1dab805685dd5b572fead4a/cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | 1 | 46 |
ExpediaGroup/cyclotron:cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee:2:raw_corpus | raw_corpus | $hitbox.on 'click', (event) ->
event.preventDefault()
isSidebarExpanded = !isSidebarExpanded
updateExpandedState()
$clickCover.on 'click', (event) ->
event.preventDefault()
isSidebarExpanded = false
updateExpand... | CoffeeScript | ExpediaGroup/cyclotron | cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | MIT | aa249eacd2cdb7409ce6c4581e1cedf99c9471b7 | 1,544 | https://github.com/ExpediaGroup/cyclotron/blob/aa249eacd2cdb7409ce6c4581e1cedf99c9471b7/cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | 48 | 90 | ||
ExpediaGroup/cyclotron:cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee:2:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
$hitbox.on 'click', (event) ->
event.preventDefault()
isSidebarExpanded = !isSidebarExpanded
updateExpandedState()
$clickCover.on 'click', (event) ->
event.preventDefault()
... | var sizer, timer;
$hitbox.on('click', function(event) {
var isSidebarExpanded;
event.preventDefault();
isSidebarExpanded = !isSidebarExpanded;
return updateExpandedState();
});
$clickCover.on('click', function(event) {
var isSidebarExpanded;
event.preventDefault();
isSidebarExpanded = false;
return up... | CoffeeScript | JavaScript | ExpediaGroup/cyclotron | cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | MIT | aa249eacd2cdb7409ce6c4581e1cedf99c9471b7 | 1,544 | https://github.com/ExpediaGroup/cyclotron/blob/aa249eacd2cdb7409ce6c4581e1cedf99c9471b7/cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | 48 | 90 |
ExpediaGroup/cyclotron:cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee:2:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
var sizer, timer;
$hitbox.on('click', function(event) {
var isSidebarExpanded;
event.preventDefault();
isSidebarExpanded = !isSidebarExpanded;
return updateExpandedState();
});
$clickCover.on('click', function(event) {
var isSidebarExpanded;
event.pre... | $hitbox.on 'click', (event) ->
event.preventDefault()
isSidebarExpanded = !isSidebarExpanded
updateExpandedState()
$clickCover.on 'click', (event) ->
event.preventDefault()
isSidebarExpanded = false
updateExpand... | JavaScript | CoffeeScript | ExpediaGroup/cyclotron | cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | MIT | aa249eacd2cdb7409ce6c4581e1cedf99c9471b7 | 1,544 | https://github.com/ExpediaGroup/cyclotron/blob/aa249eacd2cdb7409ce6c4581e1cedf99c9471b7/cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | 48 | 90 |
ExpediaGroup/cyclotron:cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee:2:completion | completion | $hitbox.on 'click', (event) ->
event.preventDefault()
isSidebarExpanded = !isSidebarExpanded
updateExpandedState()
$clickCover.on 'click', (event) ->
event.preventDefault()
isSidebarExpanded = false
updateExpand... | $element.off 'resize'
return
controller: ($scope, configService, dashboardService) ->
$scope.footerLogos = configService.dashboardSidebar?.footer?.logos || []
$scope.widgetVisibilities = []
$scope.widgetOverrides = []
$scope.allWidgetsVisible = false... | CoffeeScript | CoffeeScript | ExpediaGroup/cyclotron | cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | MIT | aa249eacd2cdb7409ce6c4581e1cedf99c9471b7 | 1,544 | https://github.com/ExpediaGroup/cyclotron/blob/aa249eacd2cdb7409ce6c4581e1cedf99c9471b7/cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | 48 | 90 |
ExpediaGroup/cyclotron:cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee:3:raw_corpus | raw_corpus | return {
label: dashboardService.getWidgetName(widget, index)
visible: visible
}
visibleWidgets = _.filter($scope.widgetVisibilities, { visible: true }).length
$scope.allWidgetsVisible = (visibleWidgets / $scope.widgetV... | CoffeeScript | ExpediaGroup/cyclotron | cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | MIT | aa249eacd2cdb7409ce6c4581e1cedf99c9471b7 | 1,544 | https://github.com/ExpediaGroup/cyclotron/blob/aa249eacd2cdb7409ce6c4581e1cedf99c9471b7/cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | 92 | 123 | ||
ExpediaGroup/cyclotron:cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee:3:completion | completion | return {
label: dashboardService.getWidgetName(widget, index)
visible: visible
}
visibleWidgets = _.filter($scope.widgetVisibilities, { visible: true }).length
$scope.allWidgetsVisible = (visibleWidgets / $scope.widgetV... | $scope.toggleAllWidgets = ->
_.each $scope.widgetOverrides, (widget) ->
widget.hidden = $scope.allWidgetsVisible
return
return
$scope.$watchCollection 'currentPage', (currentPage) ->
return unless currentPage?.length > ... | CoffeeScript | CoffeeScript | ExpediaGroup/cyclotron | cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | MIT | aa249eacd2cdb7409ce6c4581e1cedf99c9471b7 | 1,544 | https://github.com/ExpediaGroup/cyclotron/blob/aa249eacd2cdb7409ce6c4581e1cedf99c9471b7/cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | 92 | 123 |
ExpediaGroup/cyclotron:cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee:1:raw_corpus | raw_corpus | ###
# Copyright (c) 2013-2016 the original author or authors.
#
# Licensed under the MIT License (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.opensource.org/licenses/mit-license.php
#
# Unless required by applicable law ... | CoffeeScript | ExpediaGroup/cyclotron | cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | MIT | 08680403c1ab72b7789517426293681c2224eada | 1,544 | https://github.com/ExpediaGroup/cyclotron/blob/08680403c1ab72b7789517426293681c2224eada/cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | 1 | 46 | ||
ExpediaGroup/cyclotron:cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee:1:completion | completion | ###
# Copyright (c) 2013-2016 the original author or authors.
#
# Licensed under the MIT License (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.opensource.org/licenses/mit-license.php
#
# Unless required by applicable law ... | $element = $(element)
$parent = $element.parent()
$header = $element.find '.sidebar-header'
$accordion = $element.find '.sidebar-accordion'
$footer = $element.find '.sidebar-footer'
$hitbox = $element.find '.sidebar-expander-hitbox'
$expander = $el... | CoffeeScript | CoffeeScript | ExpediaGroup/cyclotron | cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | MIT | 08680403c1ab72b7789517426293681c2224eada | 1,544 | https://github.com/ExpediaGroup/cyclotron/blob/08680403c1ab72b7789517426293681c2224eada/cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | 1 | 46 |
ExpediaGroup/cyclotron:cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee:2:raw_corpus | raw_corpus | $hitbox.on 'click', (event) ->
event.preventDefault()
scope.$apply ->
scope.sidebarExpanded = !scope.sidebarExpanded
$clickCover.on 'click', (event) ->
event.preventDefault()
scope.$apply ->
scope.sideba... | CoffeeScript | ExpediaGroup/cyclotron | cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | MIT | 08680403c1ab72b7789517426293681c2224eada | 1,544 | https://github.com/ExpediaGroup/cyclotron/blob/08680403c1ab72b7789517426293681c2224eada/cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | 48 | 86 | ||
ExpediaGroup/cyclotron:cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee:2:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
$hitbox.on 'click', (event) ->
event.preventDefault()
scope.$apply ->
scope.sidebarExpanded = !scope.sidebarExpanded
$clickCover.on 'click', (event) ->
event.preventDefault()
... | var sizer, timer;
$hitbox.on('click', function(event) {
event.preventDefault();
return scope.$apply(function() {
return scope.sidebarExpanded = !scope.sidebarExpanded;
});
});
$clickCover.on('click', function(event) {
event.preventDefault();
return scope.$apply(function() {
return scope.sidebarExpan... | CoffeeScript | JavaScript | ExpediaGroup/cyclotron | cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | MIT | 08680403c1ab72b7789517426293681c2224eada | 1,544 | https://github.com/ExpediaGroup/cyclotron/blob/08680403c1ab72b7789517426293681c2224eada/cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | 48 | 86 |
ExpediaGroup/cyclotron:cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee:2:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
var sizer, timer;
$hitbox.on('click', function(event) {
event.preventDefault();
return scope.$apply(function() {
return scope.sidebarExpanded = !scope.sidebarExpanded;
});
});
$clickCover.on('click', function(event) {
event.preventDefault();
return ... | $hitbox.on 'click', (event) ->
event.preventDefault()
scope.$apply ->
scope.sidebarExpanded = !scope.sidebarExpanded
$clickCover.on 'click', (event) ->
event.preventDefault()
scope.$apply ->
scope.sideba... | JavaScript | CoffeeScript | ExpediaGroup/cyclotron | cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | MIT | 08680403c1ab72b7789517426293681c2224eada | 1,544 | https://github.com/ExpediaGroup/cyclotron/blob/08680403c1ab72b7789517426293681c2224eada/cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | 48 | 86 |
ExpediaGroup/cyclotron:cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee:2:completion | completion | $hitbox.on 'click', (event) ->
event.preventDefault()
scope.$apply ->
scope.sidebarExpanded = !scope.sidebarExpanded
$clickCover.on 'click', (event) ->
event.preventDefault()
scope.$apply ->
scope.sideba... | timer = $timeout sizer, 100
scope.$on '$destroy', ->
$timeout.cancel timer
$element.off 'resize'
return
controller: ($scope, configService, dashboardService) ->
$scope.footerLogos = configService.dashboardSidebar?.footer?.logos || []
... | CoffeeScript | CoffeeScript | ExpediaGroup/cyclotron | cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | MIT | 08680403c1ab72b7789517426293681c2224eada | 1,544 | https://github.com/ExpediaGroup/cyclotron/blob/08680403c1ab72b7789517426293681c2224eada/cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | 48 | 86 |
ExpediaGroup/cyclotron:cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee:3:raw_corpus | raw_corpus | if $scope.widgetOverrides?[index].hidden?
visible = !$scope.widgetOverrides?[index].hidden
else if widget.hidden
visible = false
return {
label: dashboardService.getWidgetName(widget, index)
... | CoffeeScript | ExpediaGroup/cyclotron | cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | MIT | 08680403c1ab72b7789517426293681c2224eada | 1,544 | https://github.com/ExpediaGroup/cyclotron/blob/08680403c1ab72b7789517426293681c2224eada/cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | 88 | 116 | ||
ExpediaGroup/cyclotron:cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee:3:completion | completion | if $scope.widgetOverrides?[index].hidden?
visible = !$scope.widgetOverrides?[index].hidden
else if widget.hidden
visible = false
return {
label: dashboardService.getWidgetName(widget, index)
... | else
$scope.widgetOverrides[index].hidden = true
return
$scope.$watch 'currentPage', (currentPage) ->
return unless currentPage?.length > 0
$scope.updateVisibility()
, true
$scope.$watch 'dashboardOverrides', (dash... | CoffeeScript | CoffeeScript | ExpediaGroup/cyclotron | cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | MIT | 08680403c1ab72b7789517426293681c2224eada | 1,544 | https://github.com/ExpediaGroup/cyclotron/blob/08680403c1ab72b7789517426293681c2224eada/cyclotron-site/app/scripts/dashboards/directives/directives.dashboardSidebar.coffee | 88 | 116 |
octoblu/meshblu:lib/Subscriber.coffee:1:raw_corpus | raw_corpus | {EventEmitter2} = require 'eventemitter2'
{createClient} = require './redis'
class Subscriber extends EventEmitter2
constructor: ({@namespace}) ->
@client = createClient()
@client.on 'message', @_onMessage
close: =>
@client.end true
subscribe: (type, uuid, callback) =>
channel = @_channel type... | CoffeeScript | octoblu/meshblu | lib/Subscriber.coffee | MIT | 04b90646685343d0bffd0da135582e4accf29efe | 815 | https://github.com/octoblu/meshblu/blob/04b90646685343d0bffd0da135582e4accf29efe/lib/Subscriber.coffee | 1 | 30 | ||
octoblu/meshblu:lib/Subscriber.coffee:1:completion | completion | {EventEmitter2} = require 'eventemitter2'
{createClient} = require './redis'
class Subscriber extends EventEmitter2
constructor: ({@namespace}) ->
@client = createClient()
@client.on 'message', @_onMessage
close: =>
@client.end true
subscribe: (type, uuid, callback) =>
channel = @_channel type... | unsubscribe: (type, uuid, callback) =>
channel = @_channel type, uuid
@client.unsubscribe channel, callback
_channel: (type, uuid) =>
"#{@namespace}:#{type}:#{uuid}"
_onMessage: (channel, messageStr) =>
try
message = JSON.parse messageStr
catch
return
@emit 'message', channel, ... | CoffeeScript | CoffeeScript | octoblu/meshblu | lib/Subscriber.coffee | MIT | 04b90646685343d0bffd0da135582e4accf29efe | 815 | https://github.com/octoblu/meshblu/blob/04b90646685343d0bffd0da135582e4accf29efe/lib/Subscriber.coffee | 1 | 30 |
octoblu/meshblu:lib/Subscriber.coffee:1:raw_corpus | raw_corpus | {EventEmitter2} = require 'eventemitter2'
{createClient} = require './redis'
class Subscriber extends EventEmitter2
constructor: ({@namespace}) ->
@client = createClient()
@client.on 'message', @_onMessage
close: =>
@client.quit()
subscribe: (type, uuid, callback) =>
channel = @_channel type,... | CoffeeScript | octoblu/meshblu | lib/Subscriber.coffee | MIT | 72cddd24e204d45824311c98318a4118e132281d | 815 | https://github.com/octoblu/meshblu/blob/72cddd24e204d45824311c98318a4118e132281d/lib/Subscriber.coffee | 1 | 31 | ||
octoblu/meshblu:lib/Subscriber.coffee:1:completion | completion | {EventEmitter2} = require 'eventemitter2'
{createClient} = require './redis'
class Subscriber extends EventEmitter2
constructor: ({@namespace}) ->
@client = createClient()
@client.on 'message', @_onMessage
close: =>
@client.quit()
subscribe: (type, uuid, callback) =>
channel = @_channel type,... | unsubscribe: (type, uuid, callback) =>
channel = @_channel type, uuid
@client.unsubscribe channel, callback
_channel: (type, uuid) =>
"#{@namespace}:#{type}:#{uuid}"
_onMessage: (channel, messageStr) =>
try
message = JSON.parse messageStr
catch
return
@emit 'message', channel, ... | CoffeeScript | CoffeeScript | octoblu/meshblu | lib/Subscriber.coffee | MIT | 72cddd24e204d45824311c98318a4118e132281d | 815 | https://github.com/octoblu/meshblu/blob/72cddd24e204d45824311c98318a4118e132281d/lib/Subscriber.coffee | 1 | 31 |
octoblu/meshblu:lib/Subscriber.coffee:1:raw_corpus | raw_corpus | {EventEmitter2} = require 'eventemitter2'
{createClient} = require './redis'
class Subscriber extends EventEmitter2
constructor: ({@namespace}) ->
@client = createClient()
@client.on 'message', (channel, message) =>
@emit 'message', channel, JSON.parse message
close: =>
@client.quit()
subsc... | CoffeeScript | octoblu/meshblu | lib/Subscriber.coffee | MIT | 522227fcd1396af7d488c8b34d61bd045bd0c85b | 815 | https://github.com/octoblu/meshblu/blob/522227fcd1396af7d488c8b34d61bd045bd0c85b/lib/Subscriber.coffee | 1 | 25 | ||
octoblu/meshblu:lib/Subscriber.coffee:1:completion | completion | {EventEmitter2} = require 'eventemitter2'
{createClient} = require './redis'
class Subscriber extends EventEmitter2
constructor: ({@namespace}) ->
@client = createClient()
@client.on 'message', (channel, message) =>
@emit 'message', channel, JSON.parse message
close: =>
@client.quit() | subscribe: (type, uuid, callback) =>
channel = @_channel type, uuid
@client.subscribe channel, callback
unsubscribe: (type, uuid, callback) =>
channel = @_channel type, uuid
@client.unsubscribe channel, callback
_channel: (type, uuid) =>
"#{@namespace}:#{type}:#{uuid}"
module.exports = Subscr... | CoffeeScript | CoffeeScript | octoblu/meshblu | lib/Subscriber.coffee | MIT | 522227fcd1396af7d488c8b34d61bd045bd0c85b | 815 | https://github.com/octoblu/meshblu/blob/522227fcd1396af7d488c8b34d61bd045bd0c85b/lib/Subscriber.coffee | 1 | 25 |
octoblu/meshblu:lib/Subscriber.coffee:1:raw_corpus | raw_corpus | {EventEmitter2} = require 'eventemitter2'
class Subscriber extends EventEmitter2
constructor: ({@namespace}, {@client}={}) ->
{createClient} = require './redis'
@client ?= createClient()
@client.on 'message', (channel, message) =>
@emit 'message', channel, JSON.parse message
subscribe: (type, u... | CoffeeScript | octoblu/meshblu | lib/Subscriber.coffee | MIT | 93182ad65c614a724122fe7f2b487af93e79ed0f | 815 | https://github.com/octoblu/meshblu/blob/93182ad65c614a724122fe7f2b487af93e79ed0f/lib/Subscriber.coffee | 1 | 22 | ||
octoblu/meshblu:lib/Subscriber.coffee:1:completion | completion | {EventEmitter2} = require 'eventemitter2'
class Subscriber extends EventEmitter2
constructor: ({@namespace}, {@client}={}) ->
{createClient} = require './redis'
@client ?= createClient()
@client.on 'message', (channel, message) =>
@emit 'message', channel, JSON.parse message
subscribe: (type, u... | channel = @_channel type, uuid
@client.subscribe channel, callback
unsubscribe: (type, uuid, callback) =>
channel = @_channel type, uuid
@client.unsubscribe channel, callback
_channel: (type, uuid) =>
"#{@namespace}:#{type}:#{uuid}"
module.exports = Subscriber | CoffeeScript | CoffeeScript | octoblu/meshblu | lib/Subscriber.coffee | MIT | 93182ad65c614a724122fe7f2b487af93e79ed0f | 815 | https://github.com/octoblu/meshblu/blob/93182ad65c614a724122fe7f2b487af93e79ed0f/lib/Subscriber.coffee | 1 | 22 |
linemanjs/lineman:config/plugins/jst.coffee:1:raw_corpus | raw_corpus | module.exports = (lineman) ->
config:
jst:
compile:
files:
"<%= files.template.generatedUnderscore %>": "<%= files.template.underscore %>" | CoffeeScript | linemanjs/lineman | config/plugins/jst.coffee | MIT | 61d681532d9621e578d319c279006bbb728ece4b | 1,168 | https://github.com/linemanjs/lineman/blob/61d681532d9621e578d319c279006bbb728ece4b/config/plugins/jst.coffee | 1 | 6 | ||
linemanjs/lineman:config/plugins/jst.coffee:1:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
module.exports = (lineman) ->
config:
jst:
compile:
files:
"<%= files.template.generatedUnderscore %>": "<%= files.template.underscore %>"
``` | module.exports = function(lineman) {
return {
config: {
jst: {
compile: {
files: {
"<%= files.template.generatedUnderscore %>": "<%= files.template.underscore %>"
}
}
}
}
};
}; | CoffeeScript | JavaScript | linemanjs/lineman | config/plugins/jst.coffee | MIT | 61d681532d9621e578d319c279006bbb728ece4b | 1,168 | https://github.com/linemanjs/lineman/blob/61d681532d9621e578d319c279006bbb728ece4b/config/plugins/jst.coffee | 1 | 6 |
linemanjs/lineman:config/plugins/jst.coffee:1:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
module.exports = function(lineman) {
return {
config: {
jst: {
compile: {
files: {
"<%= files.template.generatedUnderscore %>": "<%= files.template.underscore %>"
}
}
}
}
};
};
``` | module.exports = (lineman) ->
config:
jst:
compile:
files:
"<%= files.template.generatedUnderscore %>": "<%= files.template.underscore %>" | JavaScript | CoffeeScript | linemanjs/lineman | config/plugins/jst.coffee | MIT | 61d681532d9621e578d319c279006bbb728ece4b | 1,168 | https://github.com/linemanjs/lineman/blob/61d681532d9621e578d319c279006bbb728ece4b/config/plugins/jst.coffee | 1 | 6 |
linemanjs/lineman:config/plugins/jst.coffee:1:completion | completion | module.exports = (lineman) ->
config:
jst: | compile:
files:
"<%= files.template.generatedUnderscore %>": "<%= files.template.underscore %>" | CoffeeScript | CoffeeScript | linemanjs/lineman | config/plugins/jst.coffee | MIT | 61d681532d9621e578d319c279006bbb728ece4b | 1,168 | https://github.com/linemanjs/lineman/blob/61d681532d9621e578d319c279006bbb728ece4b/config/plugins/jst.coffee | 1 | 6 |
linemanjs/lineman:config/plugins/jst.coffee:1:raw_corpus | raw_corpus | module.exports = (lineman) ->
config:
compile:
files:
"<%= files.template.generatedUnderscore %>": "<%= files.template.underscore %>" | CoffeeScript | linemanjs/lineman | config/plugins/jst.coffee | MIT | 94365fc4e4b804de8672585c254895fbd9cb514e | 1,168 | https://github.com/linemanjs/lineman/blob/94365fc4e4b804de8672585c254895fbd9cb514e/config/plugins/jst.coffee | 1 | 5 | ||
linemanjs/lineman:config/plugins/jst.coffee:1:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
module.exports = (lineman) ->
config:
compile:
files:
"<%= files.template.generatedUnderscore %>": "<%= files.template.underscore %>"
``` | module.exports = function(lineman) {
return {
config: {
compile: {
files: {
"<%= files.template.generatedUnderscore %>": "<%= files.template.underscore %>"
}
}
}
};
}; | CoffeeScript | JavaScript | linemanjs/lineman | config/plugins/jst.coffee | MIT | 94365fc4e4b804de8672585c254895fbd9cb514e | 1,168 | https://github.com/linemanjs/lineman/blob/94365fc4e4b804de8672585c254895fbd9cb514e/config/plugins/jst.coffee | 1 | 5 |
linemanjs/lineman:config/plugins/jst.coffee:1:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
module.exports = function(lineman) {
return {
config: {
compile: {
files: {
"<%= files.template.generatedUnderscore %>": "<%= files.template.underscore %>"
}
}
}
};
};
``` | module.exports = (lineman) ->
config:
compile:
files:
"<%= files.template.generatedUnderscore %>": "<%= files.template.underscore %>" | JavaScript | CoffeeScript | linemanjs/lineman | config/plugins/jst.coffee | MIT | 94365fc4e4b804de8672585c254895fbd9cb514e | 1,168 | https://github.com/linemanjs/lineman/blob/94365fc4e4b804de8672585c254895fbd9cb514e/config/plugins/jst.coffee | 1 | 5 |
linemanjs/lineman:config/plugins/jst.coffee:1:completion | completion | module.exports = (lineman) ->
config: | compile:
files:
"<%= files.template.generatedUnderscore %>": "<%= files.template.underscore %>" | CoffeeScript | CoffeeScript | linemanjs/lineman | config/plugins/jst.coffee | MIT | 94365fc4e4b804de8672585c254895fbd9cb514e | 1,168 | https://github.com/linemanjs/lineman/blob/94365fc4e4b804de8672585c254895fbd9cb514e/config/plugins/jst.coffee | 1 | 5 |
jianliaoim/talk-os:talk-api2x/server/observers/favorite.coffee:1:raw_corpus | raw_corpus | {limbo} = require '../components'
{
SearchFavoriteModel
FavoriteModel
} = limbo.use 'talk'
FavoriteSchema = FavoriteModel.schema
FavoriteSchema.pre 'save', (next) ->
favorite = this
favorite._wasNew = favorite.isNew
next()
FavoriteSchema.post 'save', (favorite) ->
if favorite._wasNew
favorite.emit '... | CoffeeScript | jianliaoim/talk-os | talk-api2x/server/observers/favorite.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-api2x/server/observers/favorite.coffee | 1 | 25 | ||
jianliaoim/talk-os:talk-api2x/server/observers/favorite.coffee:1:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
{limbo} = require '../components'
{
SearchFavoriteModel
FavoriteModel
} = limbo.use 'talk'
FavoriteSchema = FavoriteModel.schema
FavoriteSchema.pre 'save', (next) ->
favorite = this
favorite._wasNew = favorite.isNew
next()
FavoriteSchema.post 'save'... | var FavoriteModel, FavoriteSchema, SearchFavoriteModel, limbo;
({limbo} = require('../components'));
({SearchFavoriteModel, FavoriteModel} = limbo.use('talk'));
FavoriteSchema = FavoriteModel.schema;
FavoriteSchema.pre('save', function(next) {
var favorite;
favorite = this;
favorite._wasNew = favorite.isNew;
... | CoffeeScript | JavaScript | jianliaoim/talk-os | talk-api2x/server/observers/favorite.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-api2x/server/observers/favorite.coffee | 1 | 25 |
jianliaoim/talk-os:talk-api2x/server/observers/favorite.coffee:1:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
var FavoriteModel, FavoriteSchema, SearchFavoriteModel, limbo;
({limbo} = require('../components'));
({SearchFavoriteModel, FavoriteModel} = limbo.use('talk'));
FavoriteSchema = FavoriteModel.schema;
FavoriteSchema.pre('save', function(next) {
var favorite;
... | {limbo} = require '../components'
{
SearchFavoriteModel
FavoriteModel
} = limbo.use 'talk'
FavoriteSchema = FavoriteModel.schema
FavoriteSchema.pre 'save', (next) ->
favorite = this
favorite._wasNew = favorite.isNew
next()
FavoriteSchema.post 'save', (favorite) ->
if favorite._wasNew
favorite.emit '... | JavaScript | CoffeeScript | jianliaoim/talk-os | talk-api2x/server/observers/favorite.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-api2x/server/observers/favorite.coffee | 1 | 25 |
jianliaoim/talk-os:talk-api2x/server/observers/favorite.coffee:1:completion | completion | {limbo} = require '../components'
{
SearchFavoriteModel
FavoriteModel
} = limbo.use 'talk'
FavoriteSchema = FavoriteModel.schema
FavoriteSchema.pre 'save', (next) ->
favorite = this
favorite._wasNew = favorite.isNew | next()
FavoriteSchema.post 'save', (favorite) ->
if favorite._wasNew
favorite.emit 'create', favorite
else
favorite.emit 'updated', favorite
FavoriteSchema.post 'create', (favorite) -> favorite.index()
FavoriteSchema.post 'updated', (favorite) -> favorite.index()
FavoriteSchema.post 'remove', (favorite)... | CoffeeScript | CoffeeScript | jianliaoim/talk-os | talk-api2x/server/observers/favorite.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-api2x/server/observers/favorite.coffee | 1 | 25 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:1:raw_corpus | raw_corpus | updateIfAuthorized = require '../../lib/updateIfAuthorized'
_ = require 'lodash'
describe 'updateIfAuthorized', ->
describe 'when called with a device', ->
beforeEach ->
@sut = updateIfAuthorized
@toDevice = {uuid: 'to-device', configureWhitelist: ['from-device']}
@canConfigure = sinon.stu... | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 19eb3aa62745bef5b23eb9bbac006063fdf2fd8e | 815 | https://github.com/octoblu/meshblu/blob/19eb3aa62745bef5b23eb9bbac006063fdf2fd8e/test/lib/updateIfAuthorized-spec.coffee | 1 | 41 | ||
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:1:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
updateIfAuthorized = require '../../lib/updateIfAuthorized'
_ = require 'lodash'
describe 'updateIfAuthorized', ->
describe 'when called with a device', ->
beforeEach ->
@sut = updateIfAuthorized
@toDevice = {uuid: 'to-device', configureWh... | var _, updateIfAuthorized;
updateIfAuthorized = require('../../lib/updateIfAuthorized');
_ = require('lodash');
describe('updateIfAuthorized', function() {
return describe('when called with a device', function() {
beforeEach(function() {
this.sut = updateIfAuthorized;
this.toDevice = {
uuid... | CoffeeScript | JavaScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 19eb3aa62745bef5b23eb9bbac006063fdf2fd8e | 815 | https://github.com/octoblu/meshblu/blob/19eb3aa62745bef5b23eb9bbac006063fdf2fd8e/test/lib/updateIfAuthorized-spec.coffee | 1 | 41 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:1:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
var _, updateIfAuthorized;
updateIfAuthorized = require('../../lib/updateIfAuthorized');
_ = require('lodash');
describe('updateIfAuthorized', function() {
return describe('when called with a device', function() {
beforeEach(function() {
this.sut = u... | updateIfAuthorized = require '../../lib/updateIfAuthorized'
_ = require 'lodash'
describe 'updateIfAuthorized', ->
describe 'when called with a device', ->
beforeEach ->
@sut = updateIfAuthorized
@toDevice = {uuid: 'to-device', configureWhitelist: ['from-device']}
@canConfigure = sinon.stu... | JavaScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 19eb3aa62745bef5b23eb9bbac006063fdf2fd8e | 815 | https://github.com/octoblu/meshblu/blob/19eb3aa62745bef5b23eb9bbac006063fdf2fd8e/test/lib/updateIfAuthorized-spec.coffee | 1 | 41 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:1:completion | completion | updateIfAuthorized = require '../../lib/updateIfAuthorized'
_ = require 'lodash'
describe 'updateIfAuthorized', ->
describe 'when called with a device', ->
beforeEach ->
@sut = updateIfAuthorized
@toDevice = {uuid: 'to-device', configureWhitelist: ['from-device']}
@canConfigure = sinon.stu... | @sut {uuid: 'from-device'}, {uuid: 'to-device', token: 'token'}, {$inc: {magic: 1}}, @callback, @dependencies
@device.fetch.yield null, @toDevice
it 'should call canConfigure with the fromDevice, the toDevice and the query', ->
expect(@canConfigure).to.have.been.calledWith {uuid: 'from-device'}, @toDe... | CoffeeScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 19eb3aa62745bef5b23eb9bbac006063fdf2fd8e | 815 | https://github.com/octoblu/meshblu/blob/19eb3aa62745bef5b23eb9bbac006063fdf2fd8e/test/lib/updateIfAuthorized-spec.coffee | 1 | 41 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:2:raw_corpus | raw_corpus | it 'should yield an error', ->
expect(@callback).to.have.been.called
error = @callback.firstCall.args[0]
expect(error).to.be.an.instanceOf Error
expect(error.message).to.deep.equal 'Device does not have sufficient permissions for update'
describe 'when canConfigure yields true', ->... | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 19eb3aa62745bef5b23eb9bbac006063fdf2fd8e | 815 | https://github.com/octoblu/meshblu/blob/19eb3aa62745bef5b23eb9bbac006063fdf2fd8e/test/lib/updateIfAuthorized-spec.coffee | 43 | 84 | ||
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:2:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
it 'should yield an error', ->
expect(@callback).to.have.been.called
error = @callback.firstCall.args[0]
expect(error).to.be.an.instanceOf Error
expect(error.message).to.deep.equal 'Device does not have sufficient permissions for ... | it('should yield an error', function() {
var error;
expect(this.callback).to.have.been.called;
error = this.callback.firstCall.args[0];
expect(error).to.be.an.instanceOf(Error);
return expect(error.message).to.deep.equal('Device does not have sufficient permissions for update');
});
describe('when canConfigu... | CoffeeScript | JavaScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 19eb3aa62745bef5b23eb9bbac006063fdf2fd8e | 815 | https://github.com/octoblu/meshblu/blob/19eb3aa62745bef5b23eb9bbac006063fdf2fd8e/test/lib/updateIfAuthorized-spec.coffee | 43 | 84 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:2:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
it('should yield an error', function() {
var error;
expect(this.callback).to.have.been.called;
error = this.callback.firstCall.args[0];
expect(error).to.be.an.instanceOf(Error);
return expect(error.message).to.deep.equal('Device does not have sufficient p... | it 'should yield an error', ->
expect(@callback).to.have.been.called
error = @callback.firstCall.args[0]
expect(error).to.be.an.instanceOf Error
expect(error.message).to.deep.equal 'Device does not have sufficient permissions for update'
describe 'when canConfigure yields true', ->... | JavaScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 19eb3aa62745bef5b23eb9bbac006063fdf2fd8e | 815 | https://github.com/octoblu/meshblu/blob/19eb3aa62745bef5b23eb9bbac006063fdf2fd8e/test/lib/updateIfAuthorized-spec.coffee | 43 | 84 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:2:completion | completion | it 'should yield an error', ->
expect(@callback).to.have.been.called
error = @callback.firstCall.args[0]
expect(error).to.be.an.instanceOf Error
expect(error.message).to.deep.equal 'Device does not have sufficient permissions for update'
describe 'when canConfigure yields true', ->... | describe 'when update yields an error', ->
beforeEach ->
@device.update.yield new Error('device failed to update')
it 'should call the callback with the error', ->
expect(@callback).to.have.been.called
error = @callback.firstCall.args[0]
expect(error).to.be.an.i... | CoffeeScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 19eb3aa62745bef5b23eb9bbac006063fdf2fd8e | 815 | https://github.com/octoblu/meshblu/blob/19eb3aa62745bef5b23eb9bbac006063fdf2fd8e/test/lib/updateIfAuthorized-spec.coffee | 43 | 84 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:3:raw_corpus | raw_corpus | @device.fetch.yields null, @toDevice
@Device = sinon.spy => @device
@dependencies = securityImpl: {canConfigure: @canConfigure}, Device: @Device
callback = (@error) =>
@sut {uuid: 'from-device'}, {uuid: 'uuid', token: 'token'}, null, callback, @dependencies
describe 'when canConfigure yie... | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 19eb3aa62745bef5b23eb9bbac006063fdf2fd8e | 815 | https://github.com/octoblu/meshblu/blob/19eb3aa62745bef5b23eb9bbac006063fdf2fd8e/test/lib/updateIfAuthorized-spec.coffee | 86 | 125 | ||
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:3:completion | completion | @device.fetch.yields null, @toDevice
@Device = sinon.spy => @device
@dependencies = securityImpl: {canConfigure: @canConfigure}, Device: @Device
callback = (@error) =>
@sut {uuid: 'from-device'}, {uuid: 'uuid', token: 'token'}, null, callback, @dependencies
describe 'when canConfigure yie... | @toDevice = {uuid: 'to-device', configureWhitelist: ['from-device']}
@canConfigure = sinon.stub().yields null, true
@device =
update: sinon.stub().yields null
fetch: sinon.stub().yields null, @toDevice
@Device = sinon.spy => @device
@dependencies = securityImpl: {canConfig... | CoffeeScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 19eb3aa62745bef5b23eb9bbac006063fdf2fd8e | 815 | https://github.com/octoblu/meshblu/blob/19eb3aa62745bef5b23eb9bbac006063fdf2fd8e/test/lib/updateIfAuthorized-spec.coffee | 86 | 125 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:3:raw_corpus | raw_corpus | @device.fetch.yields null, @toDevice
@Device = sinon.spy => @device
@dependencies = securityImpl: {canConfigure: @canConfigure}, Device: @Device
callback = (@error) =>
@sut {uuid: 'from-device'}, {uuid: 'uuid', token: 'token'}, null, callback, @dependencies
describe 'when canConfigure yie... | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | d50d8ea82333a9152fed00173143d5da12d17b78 | 815 | https://github.com/octoblu/meshblu/blob/d50d8ea82333a9152fed00173143d5da12d17b78/test/lib/updateIfAuthorized-spec.coffee | 86 | 100 | ||
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:3:completion | completion | @device.fetch.yields null, @toDevice
@Device = sinon.spy => @device
@dependencies = securityImpl: {canConfigure: @canConfigure}, Device: @Device
callback = (@error) =>
@sut {uuid: 'from-device'}, {uuid: 'uuid', token: 'token'}, null, callback, @dependencies | describe 'when canConfigure yields true', ->
beforeEach ->
@canConfigure.yield null, true
it 'should instantiate a Device', ->
expect(@Device).to.have.been.calledWithNew
expect(@Device).to.have.been.calledWith uuid: 'uuid' | CoffeeScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | d50d8ea82333a9152fed00173143d5da12d17b78 | 815 | https://github.com/octoblu/meshblu/blob/d50d8ea82333a9152fed00173143d5da12d17b78/test/lib/updateIfAuthorized-spec.coffee | 86 | 100 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:1:raw_corpus | raw_corpus | updateIfAuthorized = require '../../lib/updateIfAuthorized'
_ = require 'lodash'
describe 'updateIfAuthorized', ->
describe 'when called with a device', ->
beforeEach ->
@sut = updateIfAuthorized
@toDevice = {uuid: 'to-device', configureWhitelist: ['from-device']}
@getDevice = sinon.stu... | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 0ed5b43da1eab0e09db13793da134619b9a6b28e | 815 | https://github.com/octoblu/meshblu/blob/0ed5b43da1eab0e09db13793da134619b9a6b28e/test/lib/updateIfAuthorized-spec.coffee | 1 | 40 | ||
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:1:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
updateIfAuthorized = require '../../lib/updateIfAuthorized'
_ = require 'lodash'
describe 'updateIfAuthorized', ->
describe 'when called with a device', ->
beforeEach ->
@sut = updateIfAuthorized
@toDevice = {uuid: 'to-device', configureWh... | var _, updateIfAuthorized;
updateIfAuthorized = require('../../lib/updateIfAuthorized');
_ = require('lodash');
describe('updateIfAuthorized', function() {
return describe('when called with a device', function() {
beforeEach(function() {
this.sut = updateIfAuthorized;
this.toDevice = {
uuid... | CoffeeScript | JavaScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 0ed5b43da1eab0e09db13793da134619b9a6b28e | 815 | https://github.com/octoblu/meshblu/blob/0ed5b43da1eab0e09db13793da134619b9a6b28e/test/lib/updateIfAuthorized-spec.coffee | 1 | 40 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:1:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
var _, updateIfAuthorized;
updateIfAuthorized = require('../../lib/updateIfAuthorized');
_ = require('lodash');
describe('updateIfAuthorized', function() {
return describe('when called with a device', function() {
beforeEach(function() {
this.sut = u... | updateIfAuthorized = require '../../lib/updateIfAuthorized'
_ = require 'lodash'
describe 'updateIfAuthorized', ->
describe 'when called with a device', ->
beforeEach ->
@sut = updateIfAuthorized
@toDevice = {uuid: 'to-device', configureWhitelist: ['from-device']}
@getDevice = sinon.stu... | JavaScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 0ed5b43da1eab0e09db13793da134619b9a6b28e | 815 | https://github.com/octoblu/meshblu/blob/0ed5b43da1eab0e09db13793da134619b9a6b28e/test/lib/updateIfAuthorized-spec.coffee | 1 | 40 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:1:completion | completion | updateIfAuthorized = require '../../lib/updateIfAuthorized'
_ = require 'lodash'
describe 'updateIfAuthorized', ->
describe 'when called with a device', ->
beforeEach ->
@sut = updateIfAuthorized
@toDevice = {uuid: 'to-device', configureWhitelist: ['from-device']}
@getDevice = sinon.stu... | @sut {uuid: 'from-device'}, {uuid: 'to-device', token: 'token'}, {$inc: {magic: 1}}, @callback, @dependencies
it 'should call canConfigure with the fromDevice, the toDevice and the query', ->
expect(@canConfigure).to.have.been.calledWith {uuid: 'from-device'}, @toDevice, {uuid: 'to-device', token: 'token'}
... | CoffeeScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 0ed5b43da1eab0e09db13793da134619b9a6b28e | 815 | https://github.com/octoblu/meshblu/blob/0ed5b43da1eab0e09db13793da134619b9a6b28e/test/lib/updateIfAuthorized-spec.coffee | 1 | 40 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:2:raw_corpus | raw_corpus | it 'should yield an error', ->
expect(@callback).to.have.been.called
error = @callback.firstCall.args[0]
expect(error).to.be.an.instanceOf Error
expect(error.message).to.deep.equal 'Device does not have sufficient permissions for update'
describe 'when canConfigure yields true', ->... | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 0ed5b43da1eab0e09db13793da134619b9a6b28e | 815 | https://github.com/octoblu/meshblu/blob/0ed5b43da1eab0e09db13793da134619b9a6b28e/test/lib/updateIfAuthorized-spec.coffee | 42 | 82 | ||
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:2:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
it 'should yield an error', ->
expect(@callback).to.have.been.called
error = @callback.firstCall.args[0]
expect(error).to.be.an.instanceOf Error
expect(error.message).to.deep.equal 'Device does not have sufficient permissions for ... | it('should yield an error', function() {
var error;
expect(this.callback).to.have.been.called;
error = this.callback.firstCall.args[0];
expect(error).to.be.an.instanceOf(Error);
return expect(error.message).to.deep.equal('Device does not have sufficient permissions for update');
});
describe('when canConfigu... | CoffeeScript | JavaScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 0ed5b43da1eab0e09db13793da134619b9a6b28e | 815 | https://github.com/octoblu/meshblu/blob/0ed5b43da1eab0e09db13793da134619b9a6b28e/test/lib/updateIfAuthorized-spec.coffee | 42 | 82 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:2:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
it('should yield an error', function() {
var error;
expect(this.callback).to.have.been.called;
error = this.callback.firstCall.args[0];
expect(error).to.be.an.instanceOf(Error);
return expect(error.message).to.deep.equal('Device does not have sufficient p... | it 'should yield an error', ->
expect(@callback).to.have.been.called
error = @callback.firstCall.args[0]
expect(error).to.be.an.instanceOf Error
expect(error.message).to.deep.equal 'Device does not have sufficient permissions for update'
describe 'when canConfigure yields true', ->... | JavaScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 0ed5b43da1eab0e09db13793da134619b9a6b28e | 815 | https://github.com/octoblu/meshblu/blob/0ed5b43da1eab0e09db13793da134619b9a6b28e/test/lib/updateIfAuthorized-spec.coffee | 42 | 82 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:2:completion | completion | it 'should yield an error', ->
expect(@callback).to.have.been.called
error = @callback.firstCall.args[0]
expect(error).to.be.an.instanceOf Error
expect(error.message).to.deep.equal 'Device does not have sufficient permissions for update'
describe 'when canConfigure yields true', ->... | it 'should call update on the device', ->
expect(@device.update).to.have.been.calledWith {$inc: {magic: 1}}
describe 'when update yields no error', ->
beforeEach ->
@device.update.yield null
it 'should call sendConfigActivity', ->
expect(@sendConfigActivity).to.have.b... | CoffeeScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 0ed5b43da1eab0e09db13793da134619b9a6b28e | 815 | https://github.com/octoblu/meshblu/blob/0ed5b43da1eab0e09db13793da134619b9a6b28e/test/lib/updateIfAuthorized-spec.coffee | 42 | 82 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:3:raw_corpus | raw_corpus | describe 'when called with another device', ->
beforeEach ->
@sut = updateIfAuthorized
@toDevice = {uuid: 'uuid', configureWhitelist: ['from-device']}
@getDevice = sinon.stub().yields null, @toDevice
@canConfigure = sinon.stub()
@clearCache = sinon.stub().yields null
@de... | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 0ed5b43da1eab0e09db13793da134619b9a6b28e | 815 | https://github.com/octoblu/meshblu/blob/0ed5b43da1eab0e09db13793da134619b9a6b28e/test/lib/updateIfAuthorized-spec.coffee | 84 | 107 | ||
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:3:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
describe 'when called with another device', ->
beforeEach ->
@sut = updateIfAuthorized
@toDevice = {uuid: 'uuid', configureWhitelist: ['from-device']}
@getDevice = sinon.stub().yields null, @toDevice
@canConfigure = sinon.stub(... | describe('when called with another device', function() {
beforeEach(function() {
var callback;
this.sut = updateIfAuthorized;
this.toDevice = {
uuid: 'uuid',
configureWhitelist: ['from-device']
};
this.getDevice = sinon.stub().yields(null, this.toDevice);
this.canConfigure = sinon.... | CoffeeScript | JavaScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 0ed5b43da1eab0e09db13793da134619b9a6b28e | 815 | https://github.com/octoblu/meshblu/blob/0ed5b43da1eab0e09db13793da134619b9a6b28e/test/lib/updateIfAuthorized-spec.coffee | 84 | 107 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:3:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
describe('when called with another device', function() {
beforeEach(function() {
var callback;
this.sut = updateIfAuthorized;
this.toDevice = {
uuid: 'uuid',
configureWhitelist: ['from-device']
};
this.getDevice = sinon.stub().yiel... | describe 'when called with another device', ->
beforeEach ->
@sut = updateIfAuthorized
@toDevice = {uuid: 'uuid', configureWhitelist: ['from-device']}
@getDevice = sinon.stub().yields null, @toDevice
@canConfigure = sinon.stub()
@clearCache = sinon.stub().yields null
@de... | JavaScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 0ed5b43da1eab0e09db13793da134619b9a6b28e | 815 | https://github.com/octoblu/meshblu/blob/0ed5b43da1eab0e09db13793da134619b9a6b28e/test/lib/updateIfAuthorized-spec.coffee | 84 | 107 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:3:completion | completion | describe 'when called with another device', ->
beforeEach ->
@sut = updateIfAuthorized
@toDevice = {uuid: 'uuid', configureWhitelist: ['from-device']}
@getDevice = sinon.stub().yields null, @toDevice
@canConfigure = sinon.stub()
@clearCache = sinon.stub().yields null
@de... | @dependencies = getDevice: @getDevice, securityImpl: {canConfigure: @canConfigure}, Device: @Device, clearCache: @clearCache
callback = (@error) =>
@sut {uuid: 'from-device'}, {uuid: 'uuid', token: 'token'}, null, callback, @dependencies
describe 'when canConfigure yields true', ->
beforeEach ->... | CoffeeScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 0ed5b43da1eab0e09db13793da134619b9a6b28e | 815 | https://github.com/octoblu/meshblu/blob/0ed5b43da1eab0e09db13793da134619b9a6b28e/test/lib/updateIfAuthorized-spec.coffee | 84 | 107 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:1:raw_corpus | raw_corpus | updateIfAuthorized = require '../../lib/updateIfAuthorized'
_ = require 'lodash'
describe 'updateIfAuthorized', ->
describe 'when called with a device', ->
beforeEach ->
@sut = updateIfAuthorized
@toDevice = {uuid: 'to-device', configureWhitelist: ['from-device']}
@getDevice = sinon.stu... | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | d2fe972e793c979918535896e291b39ff8c6099a | 815 | https://github.com/octoblu/meshblu/blob/d2fe972e793c979918535896e291b39ff8c6099a/test/lib/updateIfAuthorized-spec.coffee | 1 | 40 | ||
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:1:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
updateIfAuthorized = require '../../lib/updateIfAuthorized'
_ = require 'lodash'
describe 'updateIfAuthorized', ->
describe 'when called with a device', ->
beforeEach ->
@sut = updateIfAuthorized
@toDevice = {uuid: 'to-device', configureWh... | var _, updateIfAuthorized;
updateIfAuthorized = require('../../lib/updateIfAuthorized');
_ = require('lodash');
describe('updateIfAuthorized', function() {
return describe('when called with a device', function() {
beforeEach(function() {
this.sut = updateIfAuthorized;
this.toDevice = {
uuid... | CoffeeScript | JavaScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | d2fe972e793c979918535896e291b39ff8c6099a | 815 | https://github.com/octoblu/meshblu/blob/d2fe972e793c979918535896e291b39ff8c6099a/test/lib/updateIfAuthorized-spec.coffee | 1 | 40 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:1:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
var _, updateIfAuthorized;
updateIfAuthorized = require('../../lib/updateIfAuthorized');
_ = require('lodash');
describe('updateIfAuthorized', function() {
return describe('when called with a device', function() {
beforeEach(function() {
this.sut = u... | updateIfAuthorized = require '../../lib/updateIfAuthorized'
_ = require 'lodash'
describe 'updateIfAuthorized', ->
describe 'when called with a device', ->
beforeEach ->
@sut = updateIfAuthorized
@toDevice = {uuid: 'to-device', configureWhitelist: ['from-device']}
@getDevice = sinon.stu... | JavaScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | d2fe972e793c979918535896e291b39ff8c6099a | 815 | https://github.com/octoblu/meshblu/blob/d2fe972e793c979918535896e291b39ff8c6099a/test/lib/updateIfAuthorized-spec.coffee | 1 | 40 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:1:completion | completion | updateIfAuthorized = require '../../lib/updateIfAuthorized'
_ = require 'lodash'
describe 'updateIfAuthorized', ->
describe 'when called with a device', ->
beforeEach ->
@sut = updateIfAuthorized
@toDevice = {uuid: 'to-device', configureWhitelist: ['from-device']}
@getDevice = sinon.stu... | @sut {uuid: 'from-device'}, {uuid: 'to-device', token: 'token'}, {$inc: {magic: 1}}, @callback, @dependencies
it 'should call canConfigure with the fromDevice, the toDevice and the query', ->
expect(@canConfigure).to.have.been.calledWith {uuid: 'from-device'}, @toDevice, {uuid: 'to-device', token: 'token'}
... | CoffeeScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | d2fe972e793c979918535896e291b39ff8c6099a | 815 | https://github.com/octoblu/meshblu/blob/d2fe972e793c979918535896e291b39ff8c6099a/test/lib/updateIfAuthorized-spec.coffee | 1 | 40 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:2:raw_corpus | raw_corpus | it 'should yield an error', ->
expect(@callback).to.have.been.called
error = @callback.firstCall.args[0]
expect(error).to.be.an.instanceOf Error
expect(error.message).to.deep.equal 'Device does not have sufficient permissions for update'
describe 'when canConfigure yields true', ->... | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | d2fe972e793c979918535896e291b39ff8c6099a | 815 | https://github.com/octoblu/meshblu/blob/d2fe972e793c979918535896e291b39ff8c6099a/test/lib/updateIfAuthorized-spec.coffee | 42 | 82 | ||
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:2:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
it 'should yield an error', ->
expect(@callback).to.have.been.called
error = @callback.firstCall.args[0]
expect(error).to.be.an.instanceOf Error
expect(error.message).to.deep.equal 'Device does not have sufficient permissions for ... | it('should yield an error', function() {
var error;
expect(this.callback).to.have.been.called;
error = this.callback.firstCall.args[0];
expect(error).to.be.an.instanceOf(Error);
return expect(error.message).to.deep.equal('Device does not have sufficient permissions for update');
});
describe('when canConfigu... | CoffeeScript | JavaScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | d2fe972e793c979918535896e291b39ff8c6099a | 815 | https://github.com/octoblu/meshblu/blob/d2fe972e793c979918535896e291b39ff8c6099a/test/lib/updateIfAuthorized-spec.coffee | 42 | 82 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:2:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
it('should yield an error', function() {
var error;
expect(this.callback).to.have.been.called;
error = this.callback.firstCall.args[0];
expect(error).to.be.an.instanceOf(Error);
return expect(error.message).to.deep.equal('Device does not have sufficient p... | it 'should yield an error', ->
expect(@callback).to.have.been.called
error = @callback.firstCall.args[0]
expect(error).to.be.an.instanceOf Error
expect(error.message).to.deep.equal 'Device does not have sufficient permissions for update'
describe 'when canConfigure yields true', ->... | JavaScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | d2fe972e793c979918535896e291b39ff8c6099a | 815 | https://github.com/octoblu/meshblu/blob/d2fe972e793c979918535896e291b39ff8c6099a/test/lib/updateIfAuthorized-spec.coffee | 42 | 82 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:2:completion | completion | it 'should yield an error', ->
expect(@callback).to.have.been.called
error = @callback.firstCall.args[0]
expect(error).to.be.an.instanceOf Error
expect(error.message).to.deep.equal 'Device does not have sufficient permissions for update'
describe 'when canConfigure yields true', ->... | it 'should call update on the device', ->
expect(@device.update).to.have.been.calledWith {$inc: {magic: 1}}
it 'should call sendConfigActivity', ->
expect(@sendConfigActivity).to.have.been.calledWith 'to-device'
describe 'when update yields an error', ->
beforeEach ->
@de... | CoffeeScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | d2fe972e793c979918535896e291b39ff8c6099a | 815 | https://github.com/octoblu/meshblu/blob/d2fe972e793c979918535896e291b39ff8c6099a/test/lib/updateIfAuthorized-spec.coffee | 42 | 82 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:3:raw_corpus | raw_corpus | @toDevice = {uuid: 'uuid', configureWhitelist: ['from-device']}
@getDevice = sinon.stub().yields null, @toDevice
@canConfigure = sinon.stub()
@clearCache = sinon.stub().yields null
@device = update: sinon.spy()
@Device = sinon.spy => @device
@dependencies = getDevice: @getDe... | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | d2fe972e793c979918535896e291b39ff8c6099a | 815 | https://github.com/octoblu/meshblu/blob/d2fe972e793c979918535896e291b39ff8c6099a/test/lib/updateIfAuthorized-spec.coffee | 84 | 103 | ||
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:3:completion | completion | @toDevice = {uuid: 'uuid', configureWhitelist: ['from-device']}
@getDevice = sinon.stub().yields null, @toDevice
@canConfigure = sinon.stub()
@clearCache = sinon.stub().yields null
@device = update: sinon.spy()
@Device = sinon.spy => @device
@dependencies = getDevice: @getDe... | callback = (@error) =>
@sut {uuid: 'from-device'}, {uuid: 'uuid', token: 'token'}, null, callback, @dependencies
describe 'when canConfigure yields true', ->
beforeEach ->
@canConfigure.yield null, true
it 'should instantiate a Device', ->
expect(@Device).to.have.been.calledWithN... | CoffeeScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | d2fe972e793c979918535896e291b39ff8c6099a | 815 | https://github.com/octoblu/meshblu/blob/d2fe972e793c979918535896e291b39ff8c6099a/test/lib/updateIfAuthorized-spec.coffee | 84 | 103 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:3:raw_corpus | raw_corpus | @toDevice = {uuid: 'uuid', configureWhitelist: ['from-device']}
@getDevice = sinon.stub().yields null, @toDevice
@canConfigure = sinon.stub()
@device = update: sinon.spy()
@Device = sinon.spy => @device
@dependencies = getDevice: @getDevice, securityImpl: {canConfigure: @canConfig... | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | cb391c74d09b0a15a42c95b0dc884034632400d8 | 815 | https://github.com/octoblu/meshblu/blob/cb391c74d09b0a15a42c95b0dc884034632400d8/test/lib/updateIfAuthorized-spec.coffee | 84 | 102 | ||
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:3:completion | completion | @toDevice = {uuid: 'uuid', configureWhitelist: ['from-device']}
@getDevice = sinon.stub().yields null, @toDevice
@canConfigure = sinon.stub()
@device = update: sinon.spy()
@Device = sinon.spy => @device
@dependencies = getDevice: @getDevice, securityImpl: {canConfigure: @canConfig... | callback = (@error) =>
@sut {uuid: 'from-device'}, {uuid: 'uuid', token: 'token'}, null, callback, @dependencies
describe 'when canConfigure yields true', ->
beforeEach ->
@canConfigure.yield null, true
it 'should instantiate a Device', ->
expect(@Device).to.have.been.calledWithN... | CoffeeScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | cb391c74d09b0a15a42c95b0dc884034632400d8 | 815 | https://github.com/octoblu/meshblu/blob/cb391c74d09b0a15a42c95b0dc884034632400d8/test/lib/updateIfAuthorized-spec.coffee | 84 | 102 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:1:raw_corpus | raw_corpus | updateIfAuthorized = require '../../lib/updateIfAuthorized'
_ = require 'lodash'
describe 'updateIfAuthorized', ->
describe 'when called with a device', ->
beforeEach ->
@sut = updateIfAuthorized
@toDevice = {uuid: 'to-device', configureWhitelist: ['from-device']}
@getDevice = sinon.stu... | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 5b4e756d4d3449079e0268bf84f693a05ef4ff2e | 815 | https://github.com/octoblu/meshblu/blob/5b4e756d4d3449079e0268bf84f693a05ef4ff2e/test/lib/updateIfAuthorized-spec.coffee | 1 | 40 | ||
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:1:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
updateIfAuthorized = require '../../lib/updateIfAuthorized'
_ = require 'lodash'
describe 'updateIfAuthorized', ->
describe 'when called with a device', ->
beforeEach ->
@sut = updateIfAuthorized
@toDevice = {uuid: 'to-device', configureWh... | var _, updateIfAuthorized;
updateIfAuthorized = require('../../lib/updateIfAuthorized');
_ = require('lodash');
describe('updateIfAuthorized', function() {
return describe('when called with a device', function() {
beforeEach(function() {
this.sut = updateIfAuthorized;
this.toDevice = {
uuid... | CoffeeScript | JavaScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 5b4e756d4d3449079e0268bf84f693a05ef4ff2e | 815 | https://github.com/octoblu/meshblu/blob/5b4e756d4d3449079e0268bf84f693a05ef4ff2e/test/lib/updateIfAuthorized-spec.coffee | 1 | 40 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:1:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
var _, updateIfAuthorized;
updateIfAuthorized = require('../../lib/updateIfAuthorized');
_ = require('lodash');
describe('updateIfAuthorized', function() {
return describe('when called with a device', function() {
beforeEach(function() {
this.sut = u... | updateIfAuthorized = require '../../lib/updateIfAuthorized'
_ = require 'lodash'
describe 'updateIfAuthorized', ->
describe 'when called with a device', ->
beforeEach ->
@sut = updateIfAuthorized
@toDevice = {uuid: 'to-device', configureWhitelist: ['from-device']}
@getDevice = sinon.stu... | JavaScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 5b4e756d4d3449079e0268bf84f693a05ef4ff2e | 815 | https://github.com/octoblu/meshblu/blob/5b4e756d4d3449079e0268bf84f693a05ef4ff2e/test/lib/updateIfAuthorized-spec.coffee | 1 | 40 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:1:completion | completion | updateIfAuthorized = require '../../lib/updateIfAuthorized'
_ = require 'lodash'
describe 'updateIfAuthorized', ->
describe 'when called with a device', ->
beforeEach ->
@sut = updateIfAuthorized
@toDevice = {uuid: 'to-device', configureWhitelist: ['from-device']}
@getDevice = sinon.stu... | @sut {uuid: 'from-device'}, {uuid: 'to-device', token: 'token'}, {$inc: {magic: 1}}, @callback, @dependencies
it 'should call canConfigure with the fromDevice, the toDevice and the query', ->
expect(@canConfigure).to.have.been.calledWith {uuid: 'from-device'}, @toDevice, {uuid: 'to-device', token: 'token'}
... | CoffeeScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 5b4e756d4d3449079e0268bf84f693a05ef4ff2e | 815 | https://github.com/octoblu/meshblu/blob/5b4e756d4d3449079e0268bf84f693a05ef4ff2e/test/lib/updateIfAuthorized-spec.coffee | 1 | 40 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:1:raw_corpus | raw_corpus | updateIfAuthorized = require '../../lib/updateIfAuthorized'
_ = require 'lodash'
describe 'updateIfAuthorized', ->
describe 'when called with a device', ->
beforeEach ->
@sut = updateIfAuthorized
@toDevice = {uuid: 'to-device', configureWhitelist: ['from-device']}
@getDevice = sinon.stu... | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 67fe79bdd62b3bd1f5e75354c2af9a59dfbf85b0 | 815 | https://github.com/octoblu/meshblu/blob/67fe79bdd62b3bd1f5e75354c2af9a59dfbf85b0/test/lib/updateIfAuthorized-spec.coffee | 1 | 39 | ||
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:1:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
updateIfAuthorized = require '../../lib/updateIfAuthorized'
_ = require 'lodash'
describe 'updateIfAuthorized', ->
describe 'when called with a device', ->
beforeEach ->
@sut = updateIfAuthorized
@toDevice = {uuid: 'to-device', configureWh... | var _, updateIfAuthorized;
updateIfAuthorized = require('../../lib/updateIfAuthorized');
_ = require('lodash');
describe('updateIfAuthorized', function() {
return describe('when called with a device', function() {
beforeEach(function() {
this.sut = updateIfAuthorized;
this.toDevice = {
uuid... | CoffeeScript | JavaScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 67fe79bdd62b3bd1f5e75354c2af9a59dfbf85b0 | 815 | https://github.com/octoblu/meshblu/blob/67fe79bdd62b3bd1f5e75354c2af9a59dfbf85b0/test/lib/updateIfAuthorized-spec.coffee | 1 | 39 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:1:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
var _, updateIfAuthorized;
updateIfAuthorized = require('../../lib/updateIfAuthorized');
_ = require('lodash');
describe('updateIfAuthorized', function() {
return describe('when called with a device', function() {
beforeEach(function() {
this.sut = u... | updateIfAuthorized = require '../../lib/updateIfAuthorized'
_ = require 'lodash'
describe 'updateIfAuthorized', ->
describe 'when called with a device', ->
beforeEach ->
@sut = updateIfAuthorized
@toDevice = {uuid: 'to-device', configureWhitelist: ['from-device']}
@getDevice = sinon.stu... | JavaScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 67fe79bdd62b3bd1f5e75354c2af9a59dfbf85b0 | 815 | https://github.com/octoblu/meshblu/blob/67fe79bdd62b3bd1f5e75354c2af9a59dfbf85b0/test/lib/updateIfAuthorized-spec.coffee | 1 | 39 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:1:completion | completion | updateIfAuthorized = require '../../lib/updateIfAuthorized'
_ = require 'lodash'
describe 'updateIfAuthorized', ->
describe 'when called with a device', ->
beforeEach ->
@sut = updateIfAuthorized
@toDevice = {uuid: 'to-device', configureWhitelist: ['from-device']}
@getDevice = sinon.stu... | @sut {uuid: 'from-device'}, {uuid: 'to-device', token: 'token'}, {$inc: {magic: 1}}, @callback, @dependencies
it 'should call canConfigure with the fromDevice, the toDevice and the query', ->
expect(@canConfigure).to.have.been.calledWith {uuid: 'from-device'}, @toDevice, {uuid: 'to-device', token: 'token'}
... | CoffeeScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 67fe79bdd62b3bd1f5e75354c2af9a59dfbf85b0 | 815 | https://github.com/octoblu/meshblu/blob/67fe79bdd62b3bd1f5e75354c2af9a59dfbf85b0/test/lib/updateIfAuthorized-spec.coffee | 1 | 39 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:2:raw_corpus | raw_corpus | it 'should yield an error', ->
expect(@callback).to.have.been.called
error = @callback.firstCall.args[0]
expect(error).to.be.an.instanceOf Error
expect(error.message).to.deep.equal 'Device does not have sufficient permissions for update'
describe 'when canConfigure yields true', ->... | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 67fe79bdd62b3bd1f5e75354c2af9a59dfbf85b0 | 815 | https://github.com/octoblu/meshblu/blob/67fe79bdd62b3bd1f5e75354c2af9a59dfbf85b0/test/lib/updateIfAuthorized-spec.coffee | 41 | 82 | ||
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:2:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
it 'should yield an error', ->
expect(@callback).to.have.been.called
error = @callback.firstCall.args[0]
expect(error).to.be.an.instanceOf Error
expect(error.message).to.deep.equal 'Device does not have sufficient permissions for ... | it('should yield an error', function() {
var error;
expect(this.callback).to.have.been.called;
error = this.callback.firstCall.args[0];
expect(error).to.be.an.instanceOf(Error);
return expect(error.message).to.deep.equal('Device does not have sufficient permissions for update');
});
describe('when canConfigu... | CoffeeScript | JavaScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 67fe79bdd62b3bd1f5e75354c2af9a59dfbf85b0 | 815 | https://github.com/octoblu/meshblu/blob/67fe79bdd62b3bd1f5e75354c2af9a59dfbf85b0/test/lib/updateIfAuthorized-spec.coffee | 41 | 82 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:2:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
it('should yield an error', function() {
var error;
expect(this.callback).to.have.been.called;
error = this.callback.firstCall.args[0];
expect(error).to.be.an.instanceOf(Error);
return expect(error.message).to.deep.equal('Device does not have sufficient p... | it 'should yield an error', ->
expect(@callback).to.have.been.called
error = @callback.firstCall.args[0]
expect(error).to.be.an.instanceOf Error
expect(error.message).to.deep.equal 'Device does not have sufficient permissions for update'
describe 'when canConfigure yields true', ->... | JavaScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 67fe79bdd62b3bd1f5e75354c2af9a59dfbf85b0 | 815 | https://github.com/octoblu/meshblu/blob/67fe79bdd62b3bd1f5e75354c2af9a59dfbf85b0/test/lib/updateIfAuthorized-spec.coffee | 41 | 82 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:2:completion | completion | it 'should yield an error', ->
expect(@callback).to.have.been.called
error = @callback.firstCall.args[0]
expect(error).to.be.an.instanceOf Error
expect(error.message).to.deep.equal 'Device does not have sufficient permissions for update'
describe 'when canConfigure yields true', ->... | it 'should call update on the device', ->
expect(@device.update).to.have.been.calledWith {$inc: {magic: 1}}
describe 'when update yields an error', ->
beforeEach ->
@device.update.yield new Error('device failed to update')
it 'should call the callback with the error', ->
... | CoffeeScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 67fe79bdd62b3bd1f5e75354c2af9a59dfbf85b0 | 815 | https://github.com/octoblu/meshblu/blob/67fe79bdd62b3bd1f5e75354c2af9a59dfbf85b0/test/lib/updateIfAuthorized-spec.coffee | 41 | 82 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:3:raw_corpus | raw_corpus | @device = update: sinon.spy()
@Device = sinon.spy => @device
@dependencies = getDevice: @getDevice, securityImpl: {canConfigure: @canConfigure}, Device: @Device
callback = (@error) =>
@sut {uuid: 'from-device'}, {uuid: 'uuid', token: 'token'}, null, callback, @dependencies
describe 'when ... | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 67fe79bdd62b3bd1f5e75354c2af9a59dfbf85b0 | 815 | https://github.com/octoblu/meshblu/blob/67fe79bdd62b3bd1f5e75354c2af9a59dfbf85b0/test/lib/updateIfAuthorized-spec.coffee | 84 | 98 | ||
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:3:completion | completion | @device = update: sinon.spy()
@Device = sinon.spy => @device
@dependencies = getDevice: @getDevice, securityImpl: {canConfigure: @canConfigure}, Device: @Device
callback = (@error) =>
@sut {uuid: 'from-device'}, {uuid: 'uuid', token: 'token'}, null, callback, @dependencies | describe 'when canConfigure yields true', ->
beforeEach ->
@canConfigure.yield null, true
it 'should instantiate a Device', ->
expect(@Device).to.have.been.calledWithNew
expect(@Device).to.have.been.calledWith uuid: 'uuid' | CoffeeScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 67fe79bdd62b3bd1f5e75354c2af9a59dfbf85b0 | 815 | https://github.com/octoblu/meshblu/blob/67fe79bdd62b3bd1f5e75354c2af9a59dfbf85b0/test/lib/updateIfAuthorized-spec.coffee | 84 | 98 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:1:raw_corpus | raw_corpus | updateIfAuthorized = require '../../lib/updateIfAuthorized'
_ = require 'lodash'
describe 'updateIfAuthorized', ->
describe 'when called with a device', ->
beforeEach ->
@sut = updateIfAuthorized
@toDevice = {uuid: 'to-device', configureWhitelist: ['from-device']}
@getDevice = sinon.stu... | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 3c8a4955df38165b1bbcd1d261cd6e3fad96245f | 815 | https://github.com/octoblu/meshblu/blob/3c8a4955df38165b1bbcd1d261cd6e3fad96245f/test/lib/updateIfAuthorized-spec.coffee | 1 | 40 | ||
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:1:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
updateIfAuthorized = require '../../lib/updateIfAuthorized'
_ = require 'lodash'
describe 'updateIfAuthorized', ->
describe 'when called with a device', ->
beforeEach ->
@sut = updateIfAuthorized
@toDevice = {uuid: 'to-device', configureWh... | var _, updateIfAuthorized;
updateIfAuthorized = require('../../lib/updateIfAuthorized');
_ = require('lodash');
describe('updateIfAuthorized', function() {
return describe('when called with a device', function() {
beforeEach(function() {
this.sut = updateIfAuthorized;
this.toDevice = {
uuid... | CoffeeScript | JavaScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 3c8a4955df38165b1bbcd1d261cd6e3fad96245f | 815 | https://github.com/octoblu/meshblu/blob/3c8a4955df38165b1bbcd1d261cd6e3fad96245f/test/lib/updateIfAuthorized-spec.coffee | 1 | 40 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:1:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
var _, updateIfAuthorized;
updateIfAuthorized = require('../../lib/updateIfAuthorized');
_ = require('lodash');
describe('updateIfAuthorized', function() {
return describe('when called with a device', function() {
beforeEach(function() {
this.sut = u... | updateIfAuthorized = require '../../lib/updateIfAuthorized'
_ = require 'lodash'
describe 'updateIfAuthorized', ->
describe 'when called with a device', ->
beforeEach ->
@sut = updateIfAuthorized
@toDevice = {uuid: 'to-device', configureWhitelist: ['from-device']}
@getDevice = sinon.stu... | JavaScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 3c8a4955df38165b1bbcd1d261cd6e3fad96245f | 815 | https://github.com/octoblu/meshblu/blob/3c8a4955df38165b1bbcd1d261cd6e3fad96245f/test/lib/updateIfAuthorized-spec.coffee | 1 | 40 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:1:completion | completion | updateIfAuthorized = require '../../lib/updateIfAuthorized'
_ = require 'lodash'
describe 'updateIfAuthorized', ->
describe 'when called with a device', ->
beforeEach ->
@sut = updateIfAuthorized
@toDevice = {uuid: 'to-device', configureWhitelist: ['from-device']}
@getDevice = sinon.stu... | it 'should call canConfigure with the fromDevice, the toDevice and the query', ->
expect(@canConfigure).to.have.been.calledWith {uuid: 'from-device'}, @toDevice, {uuid: 'to-device', token: 'token'}
describe 'when canConfigure yields an error', ->
beforeEach ->
@canConfigure.yield new Error('Som... | CoffeeScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 3c8a4955df38165b1bbcd1d261cd6e3fad96245f | 815 | https://github.com/octoblu/meshblu/blob/3c8a4955df38165b1bbcd1d261cd6e3fad96245f/test/lib/updateIfAuthorized-spec.coffee | 1 | 40 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:2:raw_corpus | raw_corpus | error = @callback.firstCall.args[0]
expect(error).to.be.an.instanceOf Error
expect(error.message).to.deep.equal 'Device does not have sufficient permissions for update'
describe 'when canConfigure yields true', ->
beforeEach ->
@canConfigure.yield null, true
it 'should not have... | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 3c8a4955df38165b1bbcd1d261cd6e3fad96245f | 815 | https://github.com/octoblu/meshblu/blob/3c8a4955df38165b1bbcd1d261cd6e3fad96245f/test/lib/updateIfAuthorized-spec.coffee | 42 | 80 | ||
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:2:completion | completion | error = @callback.firstCall.args[0]
expect(error).to.be.an.instanceOf Error
expect(error.message).to.deep.equal 'Device does not have sufficient permissions for update'
describe 'when canConfigure yields true', ->
beforeEach ->
@canConfigure.yield null, true
it 'should not have... | beforeEach ->
@device.update.yield new Error('device failed to update')
it 'should call the callback with the error', ->
expect(@callback).to.have.been.called
error = @callback.firstCall.args[0]
expect(error).to.be.an.instanceOf Error
expect(error.message).to.... | CoffeeScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 3c8a4955df38165b1bbcd1d261cd6e3fad96245f | 815 | https://github.com/octoblu/meshblu/blob/3c8a4955df38165b1bbcd1d261cd6e3fad96245f/test/lib/updateIfAuthorized-spec.coffee | 42 | 80 |
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:3:raw_corpus | raw_corpus | @dependencies = getDevice: @getDevice, securityImpl: {canConfigure: @canConfigure}, Device: @Device
callback = (@error) =>
@sut {uuid: 'from-device'}, {uuid: 'uuid', token: 'token'}, null, callback, @dependencies
describe 'when canConfigure yields true', ->
beforeEach ->
@canConfigure.yi... | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 3c8a4955df38165b1bbcd1d261cd6e3fad96245f | 815 | https://github.com/octoblu/meshblu/blob/3c8a4955df38165b1bbcd1d261cd6e3fad96245f/test/lib/updateIfAuthorized-spec.coffee | 82 | 93 | ||
octoblu/meshblu:test/lib/updateIfAuthorized-spec.coffee:3:completion | completion | @dependencies = getDevice: @getDevice, securityImpl: {canConfigure: @canConfigure}, Device: @Device
callback = (@error) =>
@sut {uuid: 'from-device'}, {uuid: 'uuid', token: 'token'}, null, callback, @dependencies
describe 'when canConfigure yields true', -> | beforeEach ->
@canConfigure.yield null, true
it 'should instantiate a Device', ->
expect(@Device).to.have.been.calledWithNew
expect(@Device).to.have.been.calledWith uuid: 'uuid' | CoffeeScript | CoffeeScript | octoblu/meshblu | test/lib/updateIfAuthorized-spec.coffee | MIT | 3c8a4955df38165b1bbcd1d261cd6e3fad96245f | 815 | https://github.com/octoblu/meshblu/blob/3c8a4955df38165b1bbcd1d261cd6e3fad96245f/test/lib/updateIfAuthorized-spec.coffee | 82 | 93 |
jianliaoim/talk-os:talk-account/client/entry/template.coffee:1:raw_corpus | raw_corpus | fs = require 'fs'
path = require 'path'
stir = require 'stir-template'
React = require 'react'
config = require 'config'
ReactDOM = require 'react-dom/server'
locales = require '../locales'
assetLinks = require '../packing/asset-links'
{html, head, title, meta, link, script, body, div} = stir
Page = React.createFact... | CoffeeScript | jianliaoim/talk-os | talk-account/client/entry/template.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-account/client/entry/template.coffee | 1 | 44 | ||
jianliaoim/talk-os:talk-account/client/entry/template.coffee:1:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
fs = require 'fs'
path = require 'path'
stir = require 'stir-template'
React = require 'react'
config = require 'config'
ReactDOM = require 'react-dom/server'
locales = require '../locales'
assetLinks = require '../packing/asset-links'
{html, head, title, meta,... | var Page, React, ReactDOM, assetLinks, baidu, body, config, div, fs, googleAnalytics, head, html, link, locales, meta, mixpanel, path, script, stir, title;
fs = require('fs');
path = require('path');
stir = require('stir-template');
React = require('react');
config = require('config');
ReactDOM = require('react-d... | CoffeeScript | JavaScript | jianliaoim/talk-os | talk-account/client/entry/template.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-account/client/entry/template.coffee | 1 | 44 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.