commit stringlengths 40 40 | subject stringlengths 1 3.25k | old_file stringlengths 4 311 | new_file stringlengths 4 311 | old_contents stringlengths 0 26.3k | lang stringclasses 3
values | proba float64 0 1 | diff stringlengths 0 7.82k |
|---|---|---|---|---|---|---|---|
910a14b597e876e491a173d3cf3d2fe9484b470e | Use fullAncestor walker | src/jsl/validate/validate.js | src/jsl/validate/validate.js | 'use strict';
const { findNodeAt } = require('acorn/dist/walk');
const { parseNode } = require('../parse');
const { throwJslError } = require('../error');
const { isJsl } = require('../test');
const { getRawJsl } = require('../tokenize');
const { getGlobalKeys } = require('./global');
const allRules = require('./rul... | JavaScript | 0 | @@ -17,26 +17,30 @@
const %7B
-findNodeAt
+base: walkBase
%7D = req
@@ -367,16 +367,517 @@
nt');%0A%0A%0A
+// TODO: remove when https://github.com/ternjs/acorn/pull/559 is merged%0Aconst fullAncestor = function (node, callback, base, state) %7B%0A if (!base) base = walkBase;%0A let ancestors = %5B%5D%0A ;(fu... |
edb329c214a96d9234bc5b11d6f13c26e5ba6d75 | Add some default options, add prototype for update these options | service/lib/crawlInstance.js | service/lib/crawlInstance.js | 'use strict';
var _ = require('lodash');
var path = require('path');
var fs = require('fs');
var Crawler = require('./crawler');
(function() {
var Instance = function(options) {
var defaults = {
skipDuplicates: true,
};
if (fs.existsSync(options || '')) {
this.options = require(options);
} else {
t... | JavaScript | 0 | @@ -12,35 +12,9 @@
';%0A%0A
-var _ = require('lodash');
%0A
+
var
@@ -57,24 +57,89 @@
uire('fs');%0A
+%0Avar _ = require('lodash');%0Avar mongoose = require('mongoose');%0A%0A
var Crawler
@@ -161,16 +161,50 @@
awler');
+%0Avar db = require('../config/db');
%0A%0A(funct
@@ -290,16 +290,134 @@
s: true,
+%0A%0A%... |
e51040fabe970f5c8a2c0dc01b9f68e209928b41 | 解决警告警告空sections绘制的问题,Listview加入属性enableEmptySections={true} | app/components/GridView.js | app/components/GridView.js | 'use strict';
import React, {PropTypes} from 'react';
import {
View,
StyleSheet,
ListView
} from 'react-native';
const propTypes = {
items: PropTypes.array,
renderItem: PropTypes.func,
style: PropTypes.func,
itemsPerRow: PropTypes.number,
onEndReached: PropTypes.func
};
class GridView extends React.Compon... | JavaScript | 0 | @@ -1472,16 +1472,51 @@
ze %7C 1%7D%0A
+ enableEmptySections=%7Btrue%7D%0A
/%3E
|
6bfcad65304b2c5892ce011e6c927624e28f7e24 | test case file creation fail | test/CLI.js | test/CLI.js | var should = require('should'),
stream = require('stream'),
CLI = require('../lib/CLI.js');
describe('CLI Tool', function () {
var optimist = {}, argv = {},
_log, _error;
beforeEach(function () {
optimist = {};
argv = {};
_log = console.log;
_error = console.error;
});
afterEac... | JavaScript | 0.000001 | @@ -1734,13 +1734,294 @@
);%0A %7D);
+%0A%0A it('should fail if output file can%5C't be created', function (done) %7B%0A CLI.prototype.error = function (error) %7B%0A error.match('Could not write to file').should.be.an.Array;%0A done();%0A %7D;%0A%0A argv = %7B output : 'nosuchDir/file' %7D;%0A ... |
75a7293c59526d429bb76775fa01e98fcb8d2f8f | connect the models to REST kraken | client/app/adapters/application.js | client/app/adapters/application.js | import DS from 'ember-data';
//export default DS.RESTAdapter.extend({
// namespace: 'api',
// host: 'http://localhost:8080'
//});
export default DS.FixtureAdapter;
| JavaScript | 0 | @@ -23,18 +23,16 @@
data';%0A%0A
-//
export d
@@ -62,18 +62,16 @@
xtend(%7B%0A
-//
namesp
@@ -82,18 +82,16 @@
'api',%0A
-//
host:
@@ -115,18 +115,18 @@
:808
-0
+8
'%0A
-//
%7D);%0A%0A
+//
expo
|
8d77744253ed1b6a2f6b17fedc8637b83b3acef2 | add more urls | src/urls.js | src/urls.js | /**
* URLS Constants
*
* @type {Object}
*/
const URLS = {
base: 'https://www.urionlinejudge.com.br',
problemView: '/judge/pt/problems/view/',
problemSubmit: 'https://www.urionlinejudge.com.br/judge/pt/runs/add/',
};
export default URLS;
| JavaScript | 0.000006 | @@ -44,32 +44,21 @@
*/%0A
+%0A
const
-URLS = %7B%0A
base
-:
+ =
'ht
@@ -88,18 +88,54 @@
e.com.br
-',
+/judge/pt';%0A%0Aconst URLS = %7B%0A base,%0A
%0A pro
@@ -148,18 +148,16 @@
ew:
-'/judge/pt
+base + '
/pro
@@ -193,61 +193,66 @@
it:
-'https://www.urionlinejudge.com.br/judge/pt/runs/add/
+base ... |
7be28e4e47d3f0bc01b0493e254d19878f3308f0 | Add 'What happens next?' heading to summary pages | client/javascript/actions/index.js | client/javascript/actions/index.js | import {
GET_RISK_ASSESSMENT_QUESTIONS,
GET_HEALTH_ASSESSMENT_QUESTIONS,
GET_OFFENDER_NOMIS_PROFILES,
GET_VIPER_SCORES,
ADD_VIPER_SCORE,
SELECT_OFFENDER,
SIGN_IN,
SIGN_OUT,
ADD_PRISONER,
CONFIRM_PRISONER,
SAVE_RISK_ASSESSMENT_ANSWER,
SAVE_HEALTHCARE_ANSWER,
COMPLETE_RISK_ASSESSMENT,
SAVE_EXI... | JavaScript | 0.000005 | @@ -307,47 +307,8 @@
NT,%0A
- SAVE_EXIT_POINT,%0A CLEAR_EXIT_POINT,%0A
CO
@@ -2502,174 +2502,8 @@
);%0A%0A
-export const saveExitPoint = riskFactor =%3E (%7B%0A type: SAVE_EXIT_POINT,%0A payload: riskFactor,%0A%7D);%0A%0Aexport const clearExitPoint = () =%3E (%7B type: CLEAR_EXIT_POINT %7D);%0A%0A
expo
|
0e6a478e6a6c4016ce6b719c3d085f4773ddec07 | Fix tests | test/app.js | test/app.js | const assert = require('assert');
var tpl = require("./template.ejs");
assert.equal(tpl({noun: "World"}), 'Hello, World!');
var tpl3 = require("./subdir/parent.ejs");
assert.equal(tpl3({foo: "foo"}), "parent: child: foo\n");
var tpl4 = require("./htmlmin.ejs");
assert.equal(tpl4({test: 123}), '123');
var tpl2 = req... | JavaScript | 0 | @@ -114,16 +114,18 @@
, World!
+%5Cn
');%0A%0Avar
@@ -218,16 +218,18 @@
d: foo%5Cn
+%5Cn
%22);%0A%0Avar
@@ -298,16 +298,18 @@
%7D), '123
+%5Cn
');%0A%0Avar
|
57b47c996e77880a0f0cfbe7214c4bbf2ec96653 | fix tests but not underlying problem | app/constants/constants.js | app/constants/constants.js | import {OPTIONS} from './../../backend/sequelizeManager';
import {CONNECTOR_URL} from './../../backend/setupServers';
export const BACKEND = {OPTIONS, CONNECTOR_URL};
export const DIALECTS = {
MYSQL: 'mysql',
MARIADB: 'mariadb',
POSTGRES: 'postgres',
MSSQL: 'mssql',
SQLITE: 'sqlite'
};
export con... | JavaScript | 0 | @@ -1,169 +1,95 @@
-im
+ex
port
-%7BOPTIONS%7D from './../../backend/sequelizeManager';%0Aimport %7BCONNECTOR_URL%7D from './../../backend/setupServers';%0A%0Aexport const BACKEND = %7BOPTIONS, CONNECTOR_URL
+const BACKEND = %7B%0A CONNECTOR_URL: 'connector.plot.ly',%0A OPTIONS: %7Bport: 5000%7D%0A
%7D;%0A%0A
|
34229cc1fa0c68d2e102f607b98e6af81c068f84 | Add new test for empty RegExp | test/ast.js | test/ast.js | /*
Copyright (C) 2012 Yusuke Suzuki <utatane.tea@gmail.com>
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright
notice, this list of conditions an... | JavaScript | 0.000002 | @@ -4279,32 +4279,458 @@
'/%5C%5C%5C%5Cu2028/i;'%0A
+ %7D,%0A %7B%0A type: 'Program',%0A body: %5B%7B%0A type: 'ExpressionStatement',%0A expression: %7B%0A type: 'Literal',%0A value: %7B%0A to... |
da17f1455fdff111b5a5e65df010f8049aa6b722 | fix show save path error | app/containers/DemoPage.js | app/containers/DemoPage.js | /**
* Created by apple on 2017/7/20.
*/
import React, { Component } from 'react';
import { Layout, Icon, Col, Tooltip, Button } from 'antd';
import LeftMenuList from '../components/menu/LeftMenuList';
import RightMenuList from '../components/menu/RightMenuList';
import UpMenuSlider from '../components/slider/UpMenuS... | JavaScript | 0.000006 | @@ -1807,17 +1807,17 @@
ert(
-'
+%60
Save in
', r
@@ -1816,14 +1816,15 @@
in
-',
+$%7B
res
+%7D%60
);%0A
@@ -2072,17 +2072,16 @@
rc === '
-
Not desi
|
b072264adc32fb7c18659c9cdd71f5468d0b9606 | add invalid output path tests | src/test/js/integration.js | src/test/js/integration.js | 'use strict';
describe('The CLI called', function () {
var run = require('../../main/js/run');
var exit = require('../../main/js/exit');
var args;
this.timeout(10000);
// chai
require('chai').should();
// std-mocks
var stdMocks = require('std-mocks');
function stdout() {
... | JavaScript | 0.000005 | @@ -4240,32 +4240,614 @@
');%0A %7D);%0A
+ it('should exit with writeErr when passed a directory path', function () %7B%0A exit.fake = true;%0A args.o = '.';%0A%0A run(args);%0A stdin.end();%0A%0A exit.records.should.eql(%5Bexit.codes.writeErr%5D);%0... |
be6b5993991462aa974e2032a382869cbada34f0 | Fix eslint complaining | test/bot.js | test/bot.js | const { AkairoClient, Constants } = require('../src/index.js');
const client = new AkairoClient({
prefix: '.',
ownerID: '123992700587343872',
commandDirectory: './test/commands/',
listenerDirectory: './test/listeners/',
inhibitorDirectory: './test/inhibitors/',
handleEdits: true,
allowMenti... | JavaScript | 0.000003 | @@ -737,16 +737,50 @@
eady!');
+ // eslint-disable-line no-console
%0A%7D);%0A%0Apr
@@ -837,9 +837,43 @@
r(err));
+ // eslint-disable-line no-console
%0A
|
bac7985ae21b9f617fa1cee993a8962369ba5c75 | Update bot.js | test/bot.js | test/bot.js | var Modularis = require('../index');
var path = require('path');
var bot = new Modularis.Client({
prefix: '!',
token: 'MjYzMTA5OTQ4NjY4Mzc5MTM2.C0NPww.pIMixDnTMUWET4fK9OSymf1yNMg',
commandPath: path.join(__dirname, '/commands/'),
delimiter: ','
});
bot.on('ready', () => console.log(bot.user.username + ... | JavaScript | 0.000001 | @@ -124,67 +124,15 @@
n: '
-MjYzMTA5OTQ4NjY4Mzc5MTM2.C0NPww.pIMixDnTMUWET4fK9OSymf1yNMg
+%3Ctoken%3E
',%0A
|
918a1ca35e1696c0b1124cae6d41c17a41920bb3 | fix linkedin and facebook | app/controllers/content.js | app/controllers/content.js | import Ember from 'ember';
import loadAll from 'ember-osf/utils/load-relationship';
export default Ember.Controller.extend({
fullScreenMFR: false,
expandedAuthors: true,
twitterHref: Ember.computed('model', function() {
return encodeURI('https://twitter.com/intent/tweet?url=' + window.location.href... | JavaScript | 0.000058 | @@ -448,34 +448,24 @@
return
-encodeURI(
'https://www
@@ -498,24 +498,43 @@
r.php?u=' +
+encodeURIComponent(
window.locat
@@ -618,34 +618,24 @@
return
-encodeURI(
'https://www
@@ -658,32 +658,51 @@
s/share?url=' +
+encodeURIComponent(
window.location.
@@ -701,24 +701,25 @@
ocation.href
+)
+ '&t... |
fb14285f1256900bb46c49fdf1e460b4c1f137a8 | build read | Resources/layouts/record.js | Resources/layouts/record.js | Layouts.record = function() {
var win = Titanium.UI.createWindow({backgroundColor: "#ccc"});
var overlay = Titanium.UI.createView();
var close_btn = Titanium.UI.createButton({
backgroundImage:"images/postrecord/return.png",
height:36,
width:38,
top:180,
left:0
});
close_btn.addEventListener('click'... | JavaScript | 0 | @@ -334,17 +334,63 @@
%7B%0A%09%09
-win.close
+Ti.Media.hideCamera();%0A%09%09win.close();%0A%09%09Layouts.stories
();%0A
|
9f0908d2ba8a97da94bfb14d69825e83aae7121b | fix FF big, add dataType to ajax | jquery.instagram.js | jquery.instagram.js | /**
* jquery.instagram.js <https://github.com/kmacrow/jquery.instagram.js>
*
* Copyright (C) Kalan MacRow, 2013
* A plugin to you embed/display a user's N most recent Instagram photos.
*
* This code is MIT licensed <http://opensource.org/licenses/MIT>
*/
(function($)
{
'use strict';
$.fn.instagram = func... | JavaScript | 0 | @@ -740,16 +740,42 @@
'GET',%0A
+ 'dataType': 'json',%0A
'd
@@ -896,32 +896,59 @@
s, xhr)%0A %7B%0A
+ console.log(data);%0A
var hits
|
ce903ff4a3ea910e7b0cfdca81ed69f9a8783226 | Fix default highlight color | caminae/mapentity/static/mapentity/leaflet-objectslayer.js | caminae/mapentity/static/mapentity/leaflet-objectslayer.js | L.ObjectsLayer = L.GeoJSON.extend({
options: {
indexing: true,
highlight: true,
objectUrl: null,
styles: {
'default': {'color': 'blue', 'weight': 2, 'opacity': 0.8},
highlight: {'color': 'red', 'weight': 5, 'opacity': 1},
select: {'color': 'red', '... | JavaScript | 0.000002 | @@ -664,24 +664,42 @@
ptions =
+ L.Util.extend(%7B%7D,
options
%7C%7C %7B%7D;%0A
@@ -694,14 +694,9 @@
ions
- %7C%7C %7B%7D
+)
;%0A%0A
@@ -1344,32 +1344,50 @@
options.style %7C%7C
+ L.Util.extend(%7B%7D,
this.options.st
@@ -1393,32 +1393,33 @@
tyles%5B'default'%5D
+)
;%0A L.Util
@@ -1477,22 +1477,34 ... |
d5b98913eb8a3d4f6f70a89bfb194d898cb0ba27 | update copyright dates from daily grunt work | js/DynamicTandem.js | js/DynamicTandem.js | // Copyright 2019, University of Colorado Boulder
/**
* A tandem for a dynamic element that stores the name of the archetype that defines its dynamic element's schema.
*
* @author Sam Reid (PhET Interactive Simulations)
* @author Chris Klusendorf (PhET Interactive Simulations)
* @author Michael Kauzmann (PhET Int... | JavaScript | 0 | @@ -10,16 +10,21 @@
ght 2019
+-2020
, Univer
|
ba3c319d874bf8bdc1344043ec7caf4580030cb0 | move constants outside of class and simplify | modules/ringo/jsgi/eventsource.js | modules/ringo/jsgi/eventsource.js | var {AsyncResponse} = require('ringo/jsgi/connector');
var objects = require('ringo/utils/objects');
/**
* EventSource (or Server-Sent-Events) is a server push technology utilizing
* plain HTTP responses. The event stream format defines three types of messages:
*
* * data-only
* * named events with data
* ... | JavaScript | 0 | @@ -95,16 +95,209 @@
cts');%0A%0A
+const CRLF = %22%5Cr%5Cn%22.toByteArray('utf-8');%0Aconst EVENT_FIELD = %22event: %22.toByteArray('utf-8');%0Aconst DATA_FIELD = %22data: %22.toByteArray('utf-8');%0Aconst COMMENT_FIELD = %22: %22.toByteArray('utf-8');%0A
/**%0A * E
@@ -1482,237 +1482,8 @@
) %7B%0A
- var CRLF = S... |
abc1579ff9b036cdb256c30d7fa0cf66bb2680b2 | remove unused code | src/static/js/modules/websocket.js | src/static/js/modules/websocket.js |
;(function() {
var global = this;
var WebSocket = function WebSocket(url, options) {
App.Core.Base.call(this, options);
this.set('url', url);
this.set('connected', false);
this.set('channels', {});
this.set('callbacks', {});
this._keepalive();
this._cre... | JavaScript | 0.000017 | @@ -2477,87 +2477,8 @@
ibe(
-function(msg) %7B%0A console.log('_resubscribe', msg);%0A %7D
);%0A
|
6b257a69c7b91a0cf9b42f3f7ee95a7119056ea1 | Make network more pullable. | t/network.js | t/network.js | var Paxos = require('..')
function Network () {
this.denizens = []
this.failures = []
this.time = 0
}
Network.prototype.receive = function (denizen, request) {
var responses = {}
request.to.forEach(function (id) {
var denizen = this.denizens[id]
if (this.failures[id] != 'isolate') ... | JavaScript | 0 | @@ -3220,24 +3220,138 @@
(arguments)%0A
+ if ((typeof (vargs%5B0%5D %7C%7C '')) != 'object') %7B%0A vargs.unshift(%7B%7D)%0A %7D%0A var response = vargs.shift()%0A
if (varg
@@ -3409,32 +3409,32 @@
.length == 0) %7B%0A
-
vargs.pu
@@ -3624,26 +3624,63 @@
requests =
-%7B%7D
+Array.isArra... |
b28544b765c6d253ebd090b2f9211506d6ca8865 | Update MultiCheck.js | src/base/MultiCheck.js | src/base/MultiCheck.js | mi2JS.addCompClass('base/MultiCheck', 'base/InputBase', '',
// component initializer function that defines constructor and adds methods to the prototype
function(proto, superProto, comp, superComp){
var mi2 = mi2JS;
if(mi2JS.applyNwGroup){
mi2JS.applyNwGroup(proto, {setValue:1,getValue:1});
}else
mi2JS.mix... | JavaScript | 0 | @@ -830,17 +830,22 @@
== null)
-
+%7B%0A%09%09%09%09
this.ite
@@ -857,16 +857,84 @@
%5D = nw;%0A
+%09%09%09%7Delse if(it%5Bi%5D.children)%7B%0A%09%09%09%09this.mapItems(it%5Bi%5D.children)%0A%09%09%09%7D%0A
%09%09%7D%0A%09%7D;%0A
|
f1d1fab9303a39787c166573642f97235c884911 | Switch the comma style | configurations/default.js | configurations/default.js | module.exports = {
"rules": {
"accessor-pairs": 2,
"array-bracket-spacing": [2, "never"],
"block-scoped-var": 2,
"block-spacing": [2, "always"],
"brace-style": [2, "1tbs"],
"camelcase": 2,
"comma-dangle": [2, "never"],
"comma-spacing": 2,
"comma-style": [2, "first"],
"computed-... | JavaScript | 0.000226 | @@ -294,11 +294,10 @@
2, %22
-fir
+la
st%22%5D
|
cf56735e294cfd0f07a8aea72cda9581e4450627 | Make better use of flatMap for hasAtLeastOneRegisteredField condition | packages/strapi-admin/services/permission/permissions-manager/index.js | packages/strapi-admin/services/permission/permissions-manager/index.js | 'use strict';
const _ = require('lodash');
const { subject: asSubject } = require('@casl/ability');
const { permittedFieldsOf } = require('@casl/ability/extra');
const { sanitizeEntity } = require('strapi-utils');
const { buildStrapiQuery, buildCaslQuery } = require('./query-builers');
module.exports = (ability, acti... | JavaScript | 0 | @@ -1337,24 +1337,10 @@
ect)
-.map(_.property(
+,
'fie
@@ -1344,18 +1344,16 @@
fields')
-))
%0A );%0A
|
587eb0349fbcfa2d90afedc1ba2ce25a0cc81d8f | print url on startup | src/tada/Tada/Server/Supervisor.js | src/tada/Tada/Server/Supervisor.js | require('./Webserver');
require('../Configuration/Factory');
require('../Configuration/FileHandler');
defineClass('Tada.Server.Supervisor', 'Consoloid.Base.Object',
{
__constructor: function(options)
{
this.__base($.extend({
tadaConfig: undefined,
env: 'prod',
netModule: require(... | JavaScript | 0.000035 | @@ -410,17 +410,16 @@
('http')
-,
%0A %7D
@@ -1669,24 +1669,36 @@
server
-on port
+at http://localhost:
%22 + this
@@ -1727,16 +1727,22 @@
r/port')
+ + '/'
);%0A%0A
|
61239962f05aad946fafb5380eefd3e739b50330 | fix dict path | src/textlint-rule-ja-no-abusage.js | src/textlint-rule-ja-no-abusage.js | // LICENSE : MIT
"use strict";
const tokenize = require("kuromojin").tokenize;
const fs = require("fs");
const path = require("path");
const prh = require("textlint-rule-prh");
const dictionaryList = require("./dictionary");
const createTokenMatcher = require("morpheme-match");
const reporter = (context) => {
const... | JavaScript | 0.000147 | @@ -746,16 +746,24 @@
e, %22..%22,
+ %22dict%22,
%22prh.ym
|
74c1dc8ff72fe4604df8bd2defca23b42edcf8c3 | Update coreValidator.js | js/coreValidator.js | js/coreValidator.js | function getArgsVal(elem, args)
{
return $(elem).closest('form').find('input[name="'+args+'"]').val();
}
Nette.validators.AppValidatorCoreValidator_greaterEqual = function(elem, args, val)
{
return val >= getArgsVal(elem, args);
};
Nette.validators.AppValidatorCoreValidator_greater = function(elem, args, val)... | JavaScript | 0 | @@ -559,32 +559,34 @@
em, args, val)%0A%7B
+
%0A return val
@@ -594,28 +594,305 @@
getArgsVal(elem, args);%0A%7D;%0A
+%0ANette.validators.AppValidatorCoreValidator_length = function(elem, args, val)%0A%7B%0A return val.length == getArgsVal(elem, args);%0A%7D;%0A%0ANette.validators.AppValidatorCoreValidator... |
f587ee7f80d59d558958a80e789fe53f905c0e73 | fix re-enable updates after saving | client/widgets/editable/helpers.js | client/widgets/editable/helpers.js | "use strict";
_.each([Template.editable, Template.editableTextarea], function(template) {
template.onCreated(function() {
// This reeks
this.state = this.data.connect(this);
});
template.onRendered(function() {
var instance = this;
var editable = this.$('.js-editable');
var initialized = false;
var changedByUs... | JavaScript | 0 | @@ -1372,16 +1372,41 @@
false);%0A
+%09%09changedByUser = false;%0A
%09%7D;%0A%0A%09va
|
35e9ec698cd8fbff1a77dc805d9ff835642c938a | Fix compilation check when new files are added to java | tasks/gwt.js | tasks/gwt.js | var args = require('yargs').argv;
var cmd = require('child_process');
var fs = require('fs-extra');
var gulp = require('gulp');
var gutil = require('gulp-util');
var rename = require('gulp-rename');
var replace = require('gulp-replace');
var git = require('gulp-git');
var insert = require('gulp-insert');
var rl = requi... | JavaScript | 0 | @@ -1551,20 +1551,26 @@
git
-diff --quiet
+status --porcelain
jav
@@ -1608,18 +1608,163 @@
stdout)
+
%7B%0A
+ if (stdout) %7B%0A gutil.log(%22%3E%3E%3E There are modifications not committed yet, forcing gwt grid compilation.%22);%0A done();%0A %7D else %7B%0A
syst
@@ -1841,16 +1841,18 @@
... |
cb72c40425e6f16430742a85346d1a67f32bb7d7 | Update controller.js | mopidy_party/static/controller.js | mopidy_party/static/controller.js | 'use strict';
// TODO : add a mopidy service designed for angular, to avoid ugly $scope.$apply()...
angular.module('partyApp', [])
.controller('MainController', function($scope) {
// Scope variables
$scope.message = [];
$scope.tracks = [];
$scope.tltracks = {
name : 'Aucune musique dans la playlist'
... | JavaScript | 0.000001 | @@ -1746,17 +1746,16 @@
tltrack)
-0
;%0A%09%09%09con
@@ -1779,16 +1779,17 @@
+ keys)
+;
%0A%09%09%09for
@@ -1868,19 +1868,15 @@
%22 +
-coordinates
+tltrack
%5Bkey
|
f9021aa55e513160974b054c00be0a1b4583b924 | Clear all with an event handler. | frontend/EscherConverter/app.js | frontend/EscherConverter/app.js | // Complete JS code.
console.log('start');
var BASE_URL = "http://localhost:6969/api";
var $ = require("cash-dom");
var nanoajax = require("nanoajax");
var saveAs = require('file-saver').saveAs;
var file_row = $('.file')[0].cloneNode(true);
var log_loaded = false;
var App = {
init: function () {
console.log('in... | JavaScript | 0 | @@ -384,12 +384,8 @@
= '
-none
';%0A
@@ -402,173 +402,74 @@
%7D;%0A%0A
-%0A// Clear all and prepare for a new conversion.%0A$('#conversion-number-new').on('click', function () %7B%0A $('#conversion-status-span').text('add files and click start'
+function cleanWorkspace() %7B%0A $('#files').find('div.file').remov... |
085e82bd654e42611f93f4b161a55f2506c6d9ab | Use ES6 classes, some login behaviour | frontend/js/components/login.js | frontend/js/components/login.js | import React from 'react';
var Login = React.createClass({
render: function(){
return (
<div className="ui form">
<div className="ui small modal active" id="login">
<div className="header">
Login
</div>
<div className="content">
<div className="... | JavaScript | 0 | @@ -25,58 +25,820 @@
';%0A%0A
-var
+class
Login
-= React.createClass(%7B%0A render: function
+extends React.Component%7B%0A constructor(props)%7B%0A super(props)%0A%0A this.state = %7B email: '', password: '' %7D%0A%0A // Really?? ES6 react...%0A this.handle_submit=this.handle_submit.bind(this)%0A ... |
38b8f69c9b276c13553115e3b6ad76f0c43b5650 | Correct chess timer for observers on game load. | frontend/js/controllers/play.js | frontend/js/controllers/play.js | /**
* Created by stas on 30.01.16.
*/
'use strict';
playzoneControllers.controller('PlayCtrl', function ($scope, $rootScope, $routeParams, GameRest, WebRTCService, WebsocketService, $interval, dateFilter) {
$scope.boardConfig = {
pieceType: 'leipzig'
};
$scope.gameConfig = {
zeitnotLimit... | JavaScript | 0 | @@ -470,32 +470,81 @@
function () %7B%0A
+ if ($scope.game.color === 'b') %7B%0A
$sco
@@ -607,16 +607,143 @@
move.id;
+%0A %7D else %7B%0A $scope.my_move = $scope.game.user_white.id === $scope.game.user_to_move.id;%0A %7D
%0A%0A
|
c1866e4013acbf601dc4aa96b62e556fc9b3e07b | fix custom js for number | picture/static/js/main.js | picture/static/js/main.js | $(function () {
$('#id_number').hide();
if ($(window).width() > 752) {
$(window).stuck();
}
if ($('.errorlist').length > 0) {
$('.open-reveal-form').click();
}
$('#line-unveil-form input[name=number_preset]').on('click', function () {
if ($('#id_number_preset_3').is(':checked')) {
$('#id_number').show... | JavaScript | 0.000001 | @@ -170,68 +170,29 @@
%7D%0A%0A%09
-$('#line-unveil-form input%5Bname=number_preset%5D').on('click',
+var check_if_custom =
fun
@@ -316,19 +316,141 @@
hide();%0A
-
%09%09%7D
+%0A%09%7D;%0A%0A%09check_if_custom();%0A%09$('#line-unveil-form input%5Bname=number_preset%5D').on('click', function () %7B%0A%09%09check_if... |
704157382c6421740fe2b861447d6fb6a3728004 | remove unused variable | corehq/couchapps/all_forms/views/view/map.js | corehq/couchapps/all_forms/views/view/map.js | function(doc) {
function get_user_id(xform_doc) {
return (xform_doc.form.meta ? xform_doc.form.meta.userID : null);
}
function get_username(xform_doc) {
return (xform_doc.form.meta ? xform_doc.form.meta.username : null);
}
var MISSING_APP_ID = "_MISSING_APP_ID";
function get_... | JavaScript | 0.00003 | @@ -1424,47 +1424,8 @@
) %7B%0A
- var status = 'submission';%0A
|
7c34bb34ce6fc7eb73bfe88aebabf1a5bf7d67c7 | Exit should wait for stdout (joyent/node#1669). | test/run.js | test/run.js | var driver = require("./driver.js");
require("./tests.js");
require("./tests-harmony.js");
var testsRun = 0, failed = 0;
function report(state, code, message) {
if (state != "ok") {++failed; console.log(code, message);}
++testsRun;
}
var t0 = +new Date;
driver.runTests(report);
console.log(testsRun + " tests run ... | JavaScript | 0 | @@ -361,16 +361,89 @@
iled) %7B%0A
+ process.stdout.once('drain', function () %7B%0A process.exit(1);%0A %7D);%0A%0A
consol
@@ -476,30 +476,19 @@
%22);%0A
- process.exit(1);%0A%7D%0A%0A
+%7D else %7B%0A
cons
@@ -507,12 +507,14 @@
passed.%22);%0A
+%7D%0A
|
7483ed405daf39acf75cfc5230646fe4df019462 | add bosh disconnect to properly close the client connection | test/bosh.js | test/bosh.js | 'use strict';
var assert = require('assert')
, http = require('http')
, xmpp = require('./../index')
, C2SStream = require('../index').C2SStream
, Client = require('node-xmpp-client')
, Message = require('node-xmpp-core').Stanza.Message
var BOSH_PORT = 45580
describe('BOSH client/server', function() {
... | JavaScript | 0 | @@ -2385,24 +2385,383 @@
)%0A %7D)
+%0A%0A it('should disconnect', function(done) %7B%0A var disconnected = false%0A cl.once('disconnect', function() %7B%0A disconnected = true%0A %7D)%0A cl.once('end', function () %7B%0A assert.ok... |
0a83651e89e12f2ede8fcd45598bdb80524b73b9 | Correct the initial explanation message | test/demo.js | test/demo.js | define([
"backbone",
"backboneRelational",
"backboneRelationalViews",
"underscore",
"jquery",
], function (bb, bbr, bbrv, us, $) {
var templateA = function(data) {
return "<div style='position:relative;left:20px'>"+data.value+"</div>";
}
var templateB = function(data) {
... | JavaScript | 0.998432 | @@ -2734,23 +2734,8 @@
v;%0A%0A
- var next;%0A%0A
@@ -3575,49 +3575,53 @@
-s1();%0A $(%22#source%22).html(s1.toString()
+var next = s1;%0A $(%22#next%22).trigger(%22click%22
);%0A%0A
|
56d492d4a6fc1ecbd6fabf31057b58c75a8a4080 | rename button | client/components/registrations/registrations.directive.js | client/components/registrations/registrations.directive.js | 'use strict';
var app = angular.module('myApp.registrations.directives', []);
app.directive('createHolding', ['Holding', 'locationHelper', '$routeParams', '$cookies', 'menu', function(Holding, locationHelper, $routeParams, $cookies, menu) {
var link = function( scope, element, attrs ) {
var domain = locationH... | JavaScript | 0.000002 | @@ -3236,20 +3236,32 @@
licking
-save
+create dashboard
, you%5C'r
|
e5dc03fe0c44c08f8f464901edbda6e35df037c6 | Remove whitespace. | facets-downloader.js | facets-downloader.js | //Required modules
var fs = require('fs'),
cheerio = require('cheerio'),
request = require('request');
var BASE_URI = 'http://www.facets.la/';
var year = 2013;
var id = 1;
/**
* Local save path on your machine
*/
var savePath = process.argv[2];
/**
* Default is a standard sized facets.la image. If you specific the... | JavaScript | 0.999153 | @@ -1784,17 +1784,16 @@
%09%7D);%0A%7D%0A%0A
-%0A
initDown
|
ce32ba26de4d49e9bf5b5049878e672dea7300d0 | remove $count tests | test/find.js | test/find.js | 'use strict';
var should = require('should');
module.exports = function(Mase, util){
should.exists(util);
var testData = [
{_id: 1, name: 'one', key: 'val'},
{_id: 2, name: 'two', key: 'val'},
{_id: 3, name: 'three'},
{_id: 4, name: 'four'}
];
it('find() or find({}) gives all documents', fun... | JavaScript | 0.000169 | @@ -439,39 +439,37 @@
) does not skip
+$
test
-ing
', function()%7B%0A
@@ -578,429 +578,45 @@
if(
-o.$result.length %3C 2)%7B return true; %7D%0A o.$break = true; return false;%0A %7D);%0A%0A result.should.have.property('length', 2);%0A result.should.be.eql(%5B%0A %7B_id: 1, name: 'one', key: ... |
cf304795d6127b03d72a55813ad8296bec89c3b9 | test deleteable set | test/gset.js | test/gset.js | var test = require('tap').test
var crdt = require('..')
test('GSet', function (t) {
var s = new crdt.Set()
s.update([['key'], {initial: true}, 0, 1])
var ary = s.get()
t.deepEqual(
ary,
{key: {initial: true}}
)
t.end()
})
test('GSet - 2', function (t) {
var s = new crdt.GSet()
s.update(... | JavaScript | 0.000001 | @@ -647,12 +647,875 @@
t.end()%0A%0A%7D)%0A
+%0Atest('validate', function (t) %7B%0A //test a set - deleteable members.%0A //pull this into it's own thing. this will be useful.%0A var array = %5B%5D%0A%0A function sort () %7B %0A return array.sort(function (a, b) %7B%0A return a.thing - b.thing%0A %7D)%... |
588c71707720b73517c1122b34c82d4690b4dba8 | Fix merge with candidate | client/src/components/advancedSearch/OrganizationFilter.js | client/src/components/advancedSearch/OrganizationFilter.js | import PropTypes from 'prop-types'
import React, { Component } from 'react'
import autobind from 'autobind-decorator'
import {Checkbox} from 'react-bootstrap'
import API from 'api'
import _isEqualWith from 'lodash/isEqualWith'
import utils from 'utils'
import Autocomplete from 'components/Autocomplete'
import {Organi... | JavaScript | 0 | @@ -2846,96 +2846,8 @@
ate%0A
-%09%09%09value.includeChildOrgs = this.state.includeChildOrgs%0A%09%09%09value.toQuery = this.toQuery%0A
%09%09%09i
|
f01a42ec6dd05be4e7f823d397d3a6a28fb6b4fc | Add connectorCapabilities global object | test/init.js | test/init.js | // Copyright IBM Corp. 2013,2016. All Rights Reserved.
// Node module: loopback-connector-mongodb
// This file is licensed under the MIT License.
// License text available at https://opensource.org/licenses/MIT
module.exports = require('should');
var DataSource = require('loopback-datasource-juggler').DataSource;
va... | JavaScript | 0 | @@ -938,16 +938,86 @@
db;%0A%7D;%0A%0A
+global.connectorCapabilities = %7B%0A ilike: false,%0A nilike: false,%0A%7D;%0A%0A
global.s
|
f7d996a9c9a405dd159b1d7114b6f974db2137bd | add lodash path | test/main.js | test/main.js | require.config({
// set baseUrl to src/
baseUrl: '../src/',
paths: {
'jquery': 'third-party/jquery/jquery.min',
'text': 'third-party/requirejs/text',
'eve': 'third-party/eve/eve',
'snap': 'third-party/snap/snap.svg-min',
'snap.plugins': 'third-party/snap.plugins/snap.... | JavaScript | 0.000005 | @@ -432,24 +432,71 @@
./test/spec'
+,%0A 'lodash': 'third-party/lodash/lodash'
%0A %7D%0A%7D);%0Ar
|
3d50408005a671c6c51df60441c76f603cdb1ab7 | Remove un used test | test/main.js | test/main.js | var
assert = require( "assert" ),
program = require( "commander" ),
fs = require("fs"),
lambda = require( "../lib/main" ),
should = require( "should" );
var result;
var program = {
environment: "development",
accessKey: "key",
secretKey: "secret",
region: "us-east-1",
functionName: "node-lambda",
handler... | JavaScript | 0.000002 | @@ -644,248 +644,10 @@
);%0A
-%0A
-describe( %22_zipfileTmpPath%22, function( ) %7B%0A it( %22generates a tmp file path%22, function( ) %7B%0A var zipfile = result._zipfileTmpPath( program );%0A zipfile.indexOf( program.functionName ).should.not.eql( -1 );%0A %7D );%0A %0A %7D );%0A
%0A d
|
c7cb64aa9f0363aa155259c767ee6715ec011eb7 | fix tests | test/main.js | test/main.js | var fs = require('fs');
var path = require('path');
var should = require('should');
var gutil = require('gulp-util');
var rimraf = require('rimraf');
var git = require('../');
require('mocha');
describe('gulp-git', function() {
describe('gulp-git normal', function(){
it('should initialize a empty git repo',... | JavaScript | 0.000001 | @@ -5463,37 +5463,45 @@
fs.readFileSync(
-'test
+__dirname + '
/test.js'))%0A
@@ -5563,14 +5563,9 @@
, '-
--patch
+n
');%0A
|
fdbef6fb9886674790c8fc67279c69c5e9d87da0 | Add more tests. | test/main.js | test/main.js | /* jshint node:true */
/* global require, it, before, beforeEach, describe */
'use strict';
var should = require('should'),
inquirer = require('inquirer'),
gulp = require('gulp'),
mockGulpDest = require('mock-gulp-dest')(gulp);
require('../slushfile');
/**
* Mock inquirer prompt
*/
function mockPrompt... | JavaScript | 0 | @@ -1672,24 +1672,1296 @@
%0A %7D);
+%0A%0A it('should add dot files to project root', function (done) %7B%0A gulp.start('default').once('stop', function () %7B%0A mockGulpDest.assertDestContains(%5B%0A '.bowerrc',%0A '.editorconfig',%0A ... |
25b47a3647dc1755fe2e8289ea9c005775aa6b0d | Correct width of stat div (for all browsers scales) | nailgun/static/js/views/common.js | nailgun/static/js/views/common.js | define(
[
'models',
'text!templates/common/navbar.html',
'text!templates/common/nodes_stats.html',
'text!templates/common/nodes_stats_popover.html',
'text!templates/common/notifications.html',
'text!templates/common/notifications_popover.html',
'text!templates/common/breadcrumb.html'
],
func... | JavaScript | 0 | @@ -4341,16 +4341,27 @@
).width(
+Math.floor(
containe
@@ -4375,24 +4375,25 @@
- barsWidth)
+)
;%0A
|
9724d1a0a966872b0101d93c959a4f3fcb4bb627 | Assert missing "node-sass" is tests | test/sass.js | test/sass.js | /*global describe, it */
'use strict';
var analyzer = require('../'),
assert = require('assert'),
scss = 'nav {\nul{ color: white }\n}',
sass = 'nav\n\tul\n\t\tcolor: white\n';
describe('SASS preprocessor', function() {
it('should be chosen for SCSS files', function() {
var preprocessors = new(require('../lib/p... | JavaScript | 0.999999 | @@ -175,16 +175,624 @@
te%5Cn';%0A%0A
+/**%0A * TODO: install and test node-sass%0A */%0Afunction testSassInstalled(done) %7B%0A%09new analyzer(sass, %7B%0A%09%09preprocessor: 'sass'%0A%09%7D, function(err, res) %7B%0A%09%09assert.strictEqual(err, null);%0A%09%09assert.equal(res.metrics.selectors, 1);%0A%09%09done();%... |
9f9d6a8bc931c0af0532ad89435aea6fb1999d60 | Make default proxy smarter | Source/Core/DefaultProxy.js | Source/Core/DefaultProxy.js | /*global define*/
define(function() {
'use strict';
/**
* A simple proxy that appends the desired resource as the sole query parameter
* to the given proxy URL.
*
* @alias DefaultProxy
* @constructor
*
* @param {String} proxy The proxy URL that will be used to requests all re... | JavaScript | 0 | @@ -636,24 +636,88 @@
resource) %7B%0A
+ var prefix = this.proxy.indexOf('?') === -1 ? '?' : '';%0A
retu
@@ -732,19 +732,22 @@
proxy +
-'?'
+prefix
+ encod
|
782ea762af9e72e50962d42b26bf1592a6df3b06 | add actual user info and some typos | jasmine-webpack/spec/AuthSpec.js | jasmine-webpack/spec/AuthSpec.js | describe("Splash page", function() {
beforeEach(function() {
window.localStorage.removeItem("sessionId")
jasmine.getFixtures().fixturesPath = './';
jasmine.getFixtures().load('index-fake.html');
});
it('should have a sign in form', function() {
window.localStorage.removeItem("sessionId")
ren... | JavaScript | 0.000001 | @@ -1042,17 +1042,16 @@
ibe('use
-r
s ajax c
@@ -1075,24 +1075,24 @@
unction() %7B%0A
+
%0A beforeE
@@ -1442,14 +1442,20 @@
it('
+should
clear
-s
sea
@@ -2260,24 +2260,274 @@
r('click')%0A%0A
+ $('.signup-form').find('input%5Bname=%22user%5Bname%5D%22%5D').val(%22Ben%22)%0A $('.signup-form').... |
62b4e5eb44c0a433010e5667ad42925712dcf82a | Add width propType | src/DataSelect.js | src/DataSelect.js | import React from 'react'
import { Component } from 'react'
import { Table, Column, Cell } from 'fixed-data-table'
import Immutable from 'immutable'
import InputHeader from './InputHeader'
import DataRow from './DataRow'
import hasClass from './utils/hasClass'
import getListFieldText from './utils/getListFieldText'
cl... | JavaScript | 0.000001 | @@ -5974,16 +5974,49 @@
quired,%0A
+ width: React.PropTypes.number,%0A
listFi
|
6c1af05992b51227386285019f82a24afd1f9759 | add `flowtype/no-types-missing-file-annotation` rule | flowtype.js | flowtype.js | module.exports = {
extends: ['plugin:flowtype/recommended', 'prettier/flowtype'],
plugins: ['flowtype'],
parser: 'babel-eslint',
settings: {
flowtype: {
onlyFilesWithFlowAnnotation: true,
},
},
rules: {
// https://github.com/gajus/eslint-plugin-flowtype
'flowtype/no-dupe-keys': 2,
... | JavaScript | 0.000001 | @@ -355,24 +355,76 @@
-types': 2,%0A
+ 'flowtype/no-types-missing-file-annotation': 2,%0A
'flowtyp
|
e62f2c270bfa9771c890d9a343961d5ee8ac485e | fix wrong duration value in onStop event | src/Dictaphone.js | src/Dictaphone.js | import Recorder from './Recorder';
const defaultConfig = {
worker: null,
workerPath: 'recordWorker',
};
export const events = {
PLAY: 'play',
PAUSE: 'pause',
START_REC: 'startRecording',
STOP_REC: 'stopRecording',
PROGRESS: 'progress',
PAUSE: 'pause',
REWIND: 'rewind'
};
export default class Dictap... | JavaScript | 0.000003 | @@ -1248,24 +1248,48 @@
cording() %7B%0A
+ const that = this;%0A%0A
if (!thi
@@ -1431,42 +1431,40 @@
ing(
-);%0A this.recorder.clear();%0A
+() =%3E %7B%0A setTimeout(() =%3E %7B
this
@@ -1491,34 +1491,34 @@
C, %7Bduration: th
-is
+at
.player.duration
@@ -1519,16 +1519,59 @@
ration%7D)
+%7D, 20... |
c997a1043b74d5cd88bfe638079c4ab4bea1c64f | Add golang template (#58) | src/utils/RuntimeHelper.js | src/utils/RuntimeHelper.js | /*
Copyright 2017 Bitnami.
Licensed under the Apache License, Version 2.0 (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.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distri... | JavaScript | 0 | @@ -1148,32 +1148,283 @@
d%0A%60%0A break%0A
+ case 'go':%0A result = %60%0Apackage kubeless%0A%0Aimport (%0A %22github.com/kubeless/kubeless/pkg/functions%22%0A)%0A%0Afunc %3C%3CHANDLER%3E%3E(event functions.Event, context functions.Context) (string, error) %7B%0A return %22Hello world!%22,... |
e53d4edb5cd174315c89a4bff0fdac1676476710 | add travis id to saucelab tunnels | karma.saucelab.conf.js | karma.saucelab.conf.js | /**
* Karma Configuration.
*/
const _ = require('lodash');
const conf = require('./karma.common.conf.js');
const browsers = {
SL_ie_11: {
base: 'SauceLabs',
browserName: 'internet explorer',
platform: 'Windows 10',
version: '11',
},
SL_ie_9: {
base: 'SauceLabs',
browserName: 'internet... | JavaScript | 0 | @@ -850,27 +850,174 @@
-startConnect: false
+build: %60TRAVIS #$%7Bprocess.env.TRAVIS_BUILD_NUMBER%7D ($%7Bprocess.env.TRAVIS_BUILD_ID%7D)%60,%0A startConnect: false,%0A tunnelIdentifier: process.env.TRAVIS_JOB_NUMBER
,%0A
|
3924cddc5c8e88b2481f66ebf4bcbae01beddb22 | allow passing non-object as reducer initial state to createReducer | src/utils/createReducer.js | src/utils/createReducer.js | import _ from 'lodash';
import invariant from 'invariant';
export default function createReducer(initialState, handlers) {
invariant(_.isObject(initialState), 'First argument of `createReducer` should be object representing initial state of reducer.');
invariant(_.isUndefined(handlers) || _.isObject(handlers), 'Seco... | JavaScript | 0.000001 | @@ -128,26 +128,30 @@
variant(
+!
_.is
-Object
+Undefined
(initial
@@ -203,22 +203,21 @@
ould be
-object
+value
represe
|
ed2790574f53bd39f9fc864a11dbb713026593f1 | Change admin_room scope to view_room | foosball.js | foosball.js | var ack = require('ac-koa').require('hipchat'),
pkg = require('./package.json'),
app = ack(pkg),
_ = require('lodash');
var addon = app.addon()
.hipchat()
.allowRoom(true)
.scopes(['send_notification','admin_room']),
msgOps = require('./lib/msg_operations.js');
addon.webhook('room_mess... | JavaScript | 0 | @@ -224,13 +224,12 @@
n','
-admin
+view
_roo
|
8d71d9b2ebe46b6a9a0396512d39c156fbe4faa9 | Reorder properties. | app/http/login/ceremony.js | app/http/login/ceremony.js | exports = module.exports = function(spawn, resume, prompt, exit) {
return {
spawn: spawn,
resume: resume,
prompt: prompt,
exit: exit
};
};
exports['@implements'] = 'http://i.bixbyjs.org/http/ceremony/Prompt';
exports['@name'] = 'login';
exports['@require'] = [
'./ceremony/spawn',
'./ceremony... | JavaScript | 0 | @@ -100,42 +100,42 @@
-resume: resume,%0A prompt: prompt
+prompt: prompt,%0A resume: resume
,%0A
|
c3d7cb4537d622e6fdb6d9379f6592ad03be4afe | Use textarea to handle linebreaks in text. | app/js/components/input.js | app/js/components/input.js | import React from 'react'
class Input extends React.Component {
constructor() {
super()
}
render() {
return (
<input onKeyUp={this.props.onType} type="text"></input>
)
}
}
export default Input;
| JavaScript | 0 | @@ -62,43 +62,8 @@
t %7B%0A
- constructor() %7B%0A super()%0A %7D%0A%0A
re
@@ -91,21 +91,24 @@
%0A %3C
-input
+textarea
onKeyUp
@@ -131,28 +131,19 @@
ype%7D
- type=%22text%22%3E%3C/input
+%3E%3C/textarea
%3E%0A
|
4ca712e9fb5b8fdf7c65c861579a528eb159db26 | Store quest informations in a structured list. | include/quest.js | include/quest.js | function Tutorial() {
var getHelps = function() {
var children = $("#helps-display").children();
var result = [];
for (var i = 0; i < children.length; i ++) {
var child = children[i];
var kbds = $("div:first", child).children();
var keys = "";
for (var j = 0; j < kbds.length; j ... | JavaScript | 0 | @@ -1,25 +1,379 @@
-function Tutorial() %7B
+var questListEN = %5B%0A %7B short:%22Level 0%22, file:%22level0.html%22, text:%22Insert text, Save file, Exit vim.%22 %7D,%0A %7B short:%22Level 1%22, file:%22level1.html%22, text:%22Blah blah blah%22 %7D,%0A %7B short:%22Level 2%22, file:%22level2.html%22, text:%22Blah ... |
7309f241b89ec386180bd0a13bd2c05fdffe8b77 | Change the initialization process | jquery.ui.autocomplete.scroll.js | jquery.ui.autocomplete.scroll.js |
$.widget('ui.autocomplete', $.ui.autocomplete, {
_resizeMenu: function() {
var ul, lis, ulW, barW;
if (isNaN(this.options.maxShowItems)) { return; }
ul = this.menu.element
.css({overflowX: '', overflowY: '', width: '', maxHeight: ''}); // Restore
lis = ul.children('li').css('whiteSpace', 'nowra... | JavaScript | 0.000046 | @@ -1,8 +1,35 @@
+%0A(function($, undefined) %7B%0A
%0A$.widge
@@ -831,8 +831,21 @@
%7D%0A%7D);%0A
+%0A%7D(jQuery));%0A
|
bd793f9de9043f03eed588f837521ec79c31f8b2 | Remove autocomplete property from search. | src/views/SearchBarView.js | src/views/SearchBarView.js | //@flow
import template from './templates/searchBar.hbs';
import LocalizationService from '../services/LocalizationService';
import keyCode from '../utils/keyCode';
const defaultOptions = () => ({
placeholder: LocalizationService.get('CORE.VIEWS.SEARCHBAR.PLACEHOLDER'),
delay: 300
});
export default... | JavaScript | 0 | @@ -291,9 +291,9 @@
ay:
-3
+2
00%0D%0A
@@ -573,24 +573,82 @@
mplate),%0D%0A%0D%0A
+ attributes: %7B%0D%0A autocomplete: false%0D%0A %7D,%0D%0A%0D%0A
template
|
3d94b088903dd058ba4f5cb718135a2c1603fc02 | Add suppressions for bug 995673, bug 995675 and bug 995679. | js/jsfunfuzz/avoid-known-bugs.js | js/jsfunfuzz/avoid-known-bugs.js | function whatToTestSpidermonkeyTrunk(code)
{
// regexps can't match across lines, so replace whitespace with spaces.
var codeL = code.replace(/\s/g, " ");
return {
allowParse: true,
allowExec: unlikelyToHang(code)
&& (jsshell || code.indexOf("nogeckoex") == -1)
,
allowIter: true,
//... | JavaScript | 0 | @@ -1519,16 +1519,412 @@
937922%0A
+ && code.indexOf(%22Math.fround%22) == -1 // bug 995673%0A && code.indexOf(%22valueOf%22) == -1 // bug 995673%0A && code.indexOf(%22Math.cos%22) == -1 // bug 995675%0A && code.indexOf(%22Math.pow%22) == -1 // bug 995... |
191bfcdd35308aa52330d2bcf8c67398a8b43f26 | Update projects.js | app/lib/router/projects.js | app/lib/router/projects.js | /* globals Router Meteor Projects */
Router.route('/', {
onBeforeAction: function () {
this.redirect('projectList', {}, {replaceState: true})
this.next()
}
})
Router.route('/projects', {
name: 'projectList',
waitOn: function () {
return [
Meteor.subscribe('directory'),
Meteor.subscribe... | JavaScript | 0 | @@ -406,17 +406,12 @@
t: %7B
-createdAt
+name
: 1%7D
|
bc5a8af2781ae0c17f913e6d9dd5dd43d1abec2b | add default view | js/lib/meshes.js/viewcontrols.js | js/lib/meshes.js/viewcontrols.js | // namespace
var MeshesJS = MeshesJS || {};
;(function() {
// global settings
var globalSettings = {
target: null,
controls: null,
camera: null,
margin: 10
};
// Constructor
function ViewControls(settings) {
var settings = _.defaultsDeep(settings || {}, Vie... | JavaScript | 0.000001 | @@ -100,24 +100,49 @@
ettings = %7B%0A
+ view: 'default',%0A
targ
@@ -318,12 +318,8 @@
ults
-Deep
(set
@@ -358,24 +358,92 @@
Settings);%0A%0A
+ this.view = null;%0A this.defaultView = settings.view;%0A
this
@@ -590,17 +590,16 @@
margin;%0A
-%0A
@@ -656,59 +656,14 @@... |
3bcb15f8cdda259e9175d6464434fe4187d44a06 | Update app.js | level2/entities/entity/app.js | level2/entities/entity/app.js | // Code goes here
var myApp = angular.module('myApp', ['angularUtils.directives.dirPagination']);
function MyController($scope, $http) {
$scope.currentPage = 1;
$scope.pageSize = 20;
$http.get("entity.json")
.then(function(response) {
$scope.entity = response.data;
});
$http.get("level.json... | JavaScript | 0.000002 | @@ -184,16 +184,114 @@
= 20;%0A
+ $scope.weekdayname = %5B'','Luned%C3%AC','Marted%C3%AC','Mercoled%C3%AC','Gioved%C3%AC','Venerd%C3%AC','Sabato','Domenica'%5D;
%0A%0A $http
|
fec2659989f1c4fb08f03563185f89bd0c0a7127 | Add answers to Task in Point when pressing confirm in PointEditScreen. Remove html elements when PointEditScreen closes. | game/prefabs/pointeditscreen.js | game/prefabs/pointeditscreen.js | 'use strict';
var LabeledButton = require('../prefabs/labeledbutton');
var GameDataCreator = require('../gamedatacreator');
var PointEditScreen = function(game, pointData) {
Phaser.Image.call(this, game, 600, 50, 'point-edit-screen');
this.pointData = pointData;
this.answerInputs = [];
this.addQuestionInput();... | JavaScript | 0 | @@ -1888,38 +1888,8 @@
t);%0A
- console.log(answerInput);%0A
%7D%0A
@@ -2079,64 +2079,625 @@
ue;%0A
- this.pointData.tasks.push(task);%0A this.destroy();%0A%7D;%0A
+%0A for (var i = 0; i %3C this.answerInputs.length; i++) %7B%0A var answer = new GameDataCreator.Answer(this.answerInputs%5Bi%5D.value, true)... |
13284e0a4d29e8818b210e72ad0cc280b7c7c8fa | Add tinycolor to the closure | js/reddit-bigspy.js | js/reddit-bigspy.js | // TODO: should not be here
var Reddit, RedditBigSpy;
(function ($) {
"use strict";
var Utils = {
"popRandom": function (arr) {
var item, index = Math.floor(Math.random() * arr.length);
item = arr[index];
arr.splice(index, 1);
return item;
},
... | JavaScript | 0 | @@ -60,16 +60,27 @@
ction ($
+, tinycolor
) %7B%0A
@@ -5086,12 +5086,30 @@
w.jQuery
+, window.tinycolor
));%0A
|
8656fcd8d17e4b0cff1ff6dafe69a9412b9d7a76 | Use 'const' | lib/cartodb/middleware/context/layergroup-token.js | lib/cartodb/middleware/context/layergroup-token.js | var LayergroupToken = require('../../models/layergroup-token');
const authErrorMessageTemplate = function (signer, user) {
return `Cannot use map signature of user "${signer}" on db of user "${user}"`;
};
module.exports = function layergroupToken () {
return function layergroupTokenMiddleware (req, res, next)... | JavaScript | 0.99853 | @@ -1,7 +1,9 @@
-var
+const
Lay
@@ -59,17 +59,16 @@
oken');%0A
-%0A
const au
|
dcf01b060457e451a9a76ee6eb685d8b0bddd591 | Fix console timer for combined data processing in data store | app/redux/reducers/data.js | app/redux/reducers/data.js | import update from 'react-addons-update';
import _ from 'lodash';
import * as actionTypes from '../constants/actionTypes';
import initialState from './initialState';
const data = (state = {}, action) => {
switch (action.type) {
case actionTypes.DATA_WORKER_ADD_DATA_SUCCESS:
return update(state, {
... | JavaScript | 0.000001 | @@ -1217,16 +1217,64 @@
mbined);
+%0A console.timeEnd('Process Combined Data');
%0A%0A
|
ba836351d3c6e339fa4cfc7199b868eba1585637 | fix bug with response on deleting note | app/routes/_note.router.js | app/routes/_note.router.js | // ```
// _todo.js
// (c) 2016 David Newman
// david.r.niciforovic@gmail.com
// _todo.js may be freely distributed under the MIT license
// ```
// */app/routes/_todo.router.js*
// ## Todo API object
// HTTP Verb Route Description
// GET /api/todo Get all of the todo items
// GET ... | JavaScript | 0 | @@ -3037,24 +3037,26 @@
ote_id%7D%60);%0A%0A
+%0A%0A
Note.r
@@ -3222,93 +3222,8 @@
');%0A
-%0A Note.find((err, notes) =%3E %7B%0A if(err)%0A res.send(err);%0A%0A
@@ -3243,21 +3243,8 @@
note
-s);%0A %7D
);%0A
|
aca52001fc1b240bd92d7254f011a0868a4ad0de | Fix route | app/routes/rounds/index.js | app/routes/rounds/index.js | import Ember from 'ember';
import UnauthenticatedRouteMixin from 'ember-simple-auth/mixins/unauthenticated-route-mixin';
export default Ember.Route.extend(UnauthenticatedRouteMixin, {
model() {
return this.get('store').query('round', {
'status__lt': 90,
});
}
});
| JavaScript | 0.000095 | @@ -259,9 +259,9 @@
t':
-9
+5
0,%0A
|
e11376b73b50c89a4bfb43a9cd4e7b418dfe78ec | update omnibox tabs on start | app/scripts/lib/omnibox.js | app/scripts/lib/omnibox.js | export default class Omnibox {
constructor(eventEmitter) {
this.eventEmitter = eventEmitter;
this.tabs = [];
this.eventEmitter.on('tabs:tabs', (tabs) => { this.tabs = tabs; });
chrome.omnibox.onInputChanged.addListener((text, suggest) => {
this.suggest(text, suggest);
});
chrome.omni... | JavaScript | 0 | @@ -183,24 +183,109 @@
tabs; %7D);%0A%0A
+ chrome.omnibox.onInputStarted.addListener(() =%3E %7B%0A this.getTabs();%0A %7D);%0A%0A
chrome.o
@@ -655,16 +655,139 @@
);%0A %7D%0A%0A
+ getTabs() %7B%0A chrome.runtime.sendMessage(%7B tabs: true %7D, (response) =%3E %7B%0A this.tabs = response.ta... |
449c7bae58f583972225cda1fbadbcd4e60734af | Change log level of profile log to INFO | src/vivliostyle/profile.js | src/vivliostyle/profile.js | /**
* Copyright 2015 Vivliostyle Inc.
* @fileoverview Utility for profiling
*/
goog.provide("vivliostyle.profile");
goog.require("vivliostyle.namespace");
goog.require("vivliostyle.logging");
goog.scope(function() {
/**
* Performance profiler measuring execution time of the script.
* @param {Performa... | JavaScript | 0.000001 | @@ -4150,13 +4150,12 @@
ger.
-debug
+info
(st)
|
84ea0cb18525b203083bbfe2ecd11ad3de9984d8 | Update namespace | lib/node_modules/@stdlib/streams/node/lib/index.js | lib/node_modules/@stdlib/streams/node/lib/index.js | /**
* @license Apache-2.0
*
* Copyright (c) 2018 The Stdlib Authors.
*
* Licensed under the Apache License, Version 2.0 (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.apache.org/licenses/LICENSE-2.0
*
* Unless required by a... | JavaScript | 0.000001 | @@ -1817,32 +1817,262 @@
ar-array' ) );%0A%0A
+/**%0A* @name constantStream%0A* @memberof streams%0A* @readonly%0A* @type %7BFunction%7D%0A* @see %7B@link module:@stdlib/streams/node/from-constant%7D%0A*/%0AsetReadOnly( streams, 'constantStream', require( '@stdlib/streams/node/from-constant' ) );%0A%0A
/**%0A* @name ... |
a888b1845fec1742451cb0aa47487de8695f1ec8 | add /r/futurology | digestion.js | digestion.js | 'use strict';
var request = require('request');
var Q = require('q');
var moment = require('moment');
require('./db');
var Post = require('mongoose').model('Post');
var reddit = {
url: 'http://www.reddit.com',
limit: 100,
uaString: 'thedigest/0.1 by connyay'
};
var echojs = {
url: 'http://www.echojs.... | JavaScript | 0 | @@ -266,16 +266,124 @@
connyay'
+,%0A subreddits: %5B'programming', 'technology', 'futurology', 'science', 'webdev', 'web_design', 'blackhat'%5D
%0A%7D;%0Avar
@@ -4443,84 +4443,25 @@
eds%0A
-%5B'programming', 'technology', 'science', 'webdev', 'web_design', 'blackhat'%5D
+reddit.subreddits
.for
|
5f4e105a16669989763e13fe9a29f961395b2efe | Update client.js | node_client_example/src/client.js | node_client_example/src/client.js | // Copyright (c) Jupyter Development Team.
// Distributed under the terms of the Modified BSD License.
var xmlhttprequest = require('xmlhttprequest');
var ws = require('ws');
var fs = require('fs');
global.XMLHttpRequest = xmlhttprequest.XMLHttpRequest;
global.WebSocket = ws;
var jupyter = require('jupyter-js-services... | JavaScript | 0.000001 | @@ -1222,16 +1222,19 @@
/158%0A
+ //
user: '
@@ -1247,16 +1247,19 @@
er',%0A
+ //
passwor
@@ -1304,16 +1304,19 @@
e OK%0A
+ //
request
@@ -1325,24 +1325,27 @@
aders: %7B%0A
+ //
'X-Some
@@ -1371,19 +1371,282 @@
ue'%0A
-%7D%0A%7D
+// %7D%0A%7D;%0A%0Aif (process.env.BASE_GATEWAY_USERNAME)... |
d98516f1243f21936bc3d915f2a2d359c820a4ff | Add missing semi-colons. | tests/spec/function/spec-wrap.js | tests/spec/function/spec-wrap.js | define(['mout/function/wrap'], function(wrap){
var add = function(a, b){
return a + b;
};
describe('function/wrap', function(){
it('should create a wrapped function', function(){
var wrapped = wrap(add, function(func, a, b){
return func(a + 2, b)
}... | JavaScript | 0.003646 | @@ -299,16 +299,17 @@
+ 2, b)
+;
%0A
@@ -359,16 +359,17 @@
.toBe(5)
+;
%0A
@@ -894,16 +894,17 @@
this.b)
+;
%0A
|
75538ca8cc9a5cfe6bb04cee4a7bf68fe478b7e8 | simplify test file | tests/unit/matrix/matrix.test.js | tests/unit/matrix/matrix.test.js | (function ( $, matrix ) {
var rresourceName = /(.+)\.\w+$/;
function resourceName( resource ) {
var resourceName = rresourceName.exec( resource );
return resourceName && resourceName[1];
}
var test = window.test = {};
test.results = [];
matrix.addHandler( "test", "module", {
load: function ( resource ) ... | JavaScript | 0.000985 | @@ -24,180 +24,8 @@
%7B%0A%0A
-%09var rresourceName = /(.+)%5C.%5Cw+$/;%0A%0A%09function resourceName( resource ) %7B%0A%09%09var resourceName = rresourceName.exec( resource );%0A%09%09return resourceName && resourceName%5B1%5D;%0A%09%7D%0A%0A
%09var
@@ -329,32 +329,39 @@
() %7B%0A%09%09%09%09%09test%5B
+matrix.
... |
e239de6c6bab29b3895d88aa6c04be9439cf1e1e | test coverage for rootLevelLearnerGroups CP. | tests/unit/models/cohort-test.js | tests/unit/models/cohort-test.js | import {
moduleForModel,
test
} from 'ember-qunit';
import modelList from '../../helpers/model-list';
import Ember from 'ember';
moduleForModel('cohort', 'Unit | Model | Cohort', {
needs :modelList
});
test('it exists', function(assert) {
let model = this.subject();
// let store = this.store();
assert.ok(... | JavaScript | 0 | @@ -127,16 +127,40 @@
mber';%0A%0A
+const %7B run %7D = Ember;%0A%0A
moduleFo
@@ -1704,12 +1704,1178 @@
%0A %7D);%0A%0A%7D);%0A
+%0Atest('list root level groups', async function(assert) %7B%0A assert.expect(3);%0A%0A const model = this.subject();%0A const store = this.store();%0A%0A run(async () =%3E %7B%0A ... |
914373280d9bc9546289beb9b1a0521bfd0d5034 | Add support for FullCalendar v2.3.2. | fullcalendar-rightclick.js | fullcalendar-rightclick.js | /*!
* fullcalendar-rightclick v1.2
* Docs & License: https://github.com/mherrmann/fullcalendar-rightclick
* (c) 2015 Michael Herrmann
*/
(function($) {
function monkeyPatchViewClass(View, dayCssClass) {
var originalRender = View.prototype.render;
View.prototype.render = function() {
originalRender.call(thi... | JavaScript | 0 | @@ -27,17 +27,17 @@
lick v1.
-2
+3
%0A * Docs
@@ -202,16 +202,117 @@
lass) %7B%0A
+%09%09View = View.class %7C%7C View;%0A%09%09var renderFn = 'render' in View.prototype ? 'render' : 'renderDates';%0A
%09%09var or
@@ -340,23 +340,26 @@
rototype
-.
+%5B
render
+Fn%5D
;%0A%09%09View
@@ -372,15 +372,18 @@
type
-.
... |
32ea52105cb4a926b2b1422fd762da223bcbb203 | Add default and invalid stories. | examples/official-storybook/stories/core/layout.stories.js | examples/official-storybook/stories/core/layout.stories.js | import React from 'react';
// eslint-disable-next-line react/prop-types
const Box = ({ children, display = 'block' }) => (
<div style={{ display, border: '2px solid #FF4785', padding: 10 }}>{children}</div>
);
export default {
title: 'Core/Layout',
};
export const PaddedBlock = () => <Box>padded</Box>;
PaddedBlo... | JavaScript | 0 | @@ -248,24 +248,84 @@
ayout',%0A%7D;%0A%0A
+export const Default = () =%3E %3CBox%3Epadded by default%3C/Box%3E;%0A%0A
export const
@@ -1080,28 +1080,155 @@
: %7B layout: 'centered' %7D %7D;%0A
+%0Aexport const Invalid = () =%3E %3CBox%3Einvalid layout value%3C/Box%3E;%0ACenteredInline.story = %7B parameters: %7B la... |
4b9cda272d3dd1c321f6228859582ac35442518a | Remove trailing-white-space (#74) | filters/multi-color-replace/src/MultiColorReplaceFilter.js | filters/multi-color-replace/src/MultiColorReplaceFilter.js | import vertex from './multi-color-replace.vert';
import fragment from './multi-color-replace.frag';
/**
* Filter for replacing a color with another color. Similar to ColorReplaceFilter, but support multiple
* colors.
* .EventEmitter
const pMap = require('p-map')
const Log = require('ipfs-log')
const Logger = require('logplease')
const logger = Logger.create('replicator', { color: Logger.Colors.Cyan })
Logger.setLogLevel('ERROR')
const nextRefsIntersection = e => [...new Set([...e.next, ...e.ref... | JavaScript | 0.000014 | @@ -261,25 +261,18 @@
nextRefs
-Intersect
+Un
ion = e
@@ -5097,17 +5097,10 @@
Refs
-Intersect
+Un
ion)
|
8a290bcd00f18c08cb1f43b6a3dc5f245203145b | Migrate to new scenegraph mark lookup method. | src/Scenegraph.js | src/Scenegraph.js | import Bounds from './Bounds';
import GroupItem from './GroupItem';
import {sceneFromJSON, sceneToJSON} from './util/serialize';
export default function Scenegraph(scene) {
if (arguments.length) {
this.root = sceneFromJSON(scene);
} else {
this.root = createMark({
marktype: 'group',
name: 'root... | JavaScript | 0 | @@ -558,400 +558,77 @@
ion(
-scenepath, markdef) %7B%0A var markpath = scenepath.marks,%0A itempath = scenepath.items,%0A item = this.root.items%5B0%5D,%0A mark, index, i, n;%0A%0A try %7B%0A for (i=0, n=markpath.length; i%3Cn; ++i) %7B%0A mark = item.items%5Bmarkpath%5Bi%5D%5D;%0A if (!m... |
71777663ed27f7c8796df4f7ac812bf361144eef | Remove BindingContents (#6764) | src/utils/pause/scopes/getScope.js | src/utils/pause/scopes/getScope.js | /* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at <http://mozilla.org/MPL/2.0/>. */
// @flow
import { ObjectInspectorUtils } from "devtools-reps";
import { getBindingVariables } from "./getVariabl... | JavaScript | 0 | @@ -477,25 +477,8 @@
cope
-, BindingContents
%7D f
|
f7dc129bdd93ca74fef33453bb57c16220b65122 | add athlete stats saga. | app/store/sagas/athlete.js | app/store/sagas/athlete.js | // redux-saga
import { takeEvery } from 'redux-saga';
import { put, call, select } from 'redux-saga/effects';
// service
import { getAthleteClubs } from '../services/athlete';
// selector
import getToken from '../selectors/token';
// actions
import { GET_ATHLETE_CLUBS } from '../constants/actionTypes';
// actions
i... | JavaScript | 0.000002 | @@ -131,32 +131,49 @@
getAthleteClubs
+, getAthleteStats
%7D from '../serv
@@ -242,16 +242,67 @@
/token';
+%0Aimport getAthleteID from '../selectors/athleteID';
%0A%0A// act
@@ -332,16 +332,35 @@
TE_CLUBS
+, GET_ATHLETE_STATS
%7D from
@@ -428,16 +428,38 @@
eteClubs
+, retrieveAthleteStats
%7D from
@@ -696... |
0017b9e7228608cde261db0ca7132d738a2a4cd1 | Fix pages not being able to be deleted from collections | src/app/utilities/api-clients/collections.js | src/app/utilities/api-clients/collections.js | import http from '../http';
export default class collections {
static get(collectionID) {
return http.get(`/zebedee/collectionDetails/${collectionID}`)
}
static getAll() {
return http.get(`/zebedee/collections`)
.then(response => {
return response;
... | JavaScript | 0 | @@ -863,92 +863,796 @@
-static deletePage(collectionID, pageURI) %7B%0A return http.delete(%60/zebedee/page
+// In CMD we're using a new endpoint to delete pages (https://github.com/ONSdigital/zebedee/blob/cmd-develop/zebedee-cms/src/main/java/com/github/onsdigital/zebedee/api/Page.java)%0A // which mea... |
0a80b3efa5039f7442b2a7d960c5a9b9c5d2fa6c | use files.dist | app/templates/_gulpfile.js | app/templates/_gulpfile.js | 'use strict';
var gulp = require('gulp');
var gutil = require('gulp-util');
var plugins = require('gulp-load-plugins')();
var files = {
src: 'src/**/*.raml',
dist: 'dist'
};
var onError = function onError (err) {
gutil.beep();
gutil.log(gutil.colors.red('Error caught:'), err);
if (process.env.IGNORE_ERROR)... | JavaScript | 0.000007 | @@ -702,22 +702,26 @@
lp.dest(
-'
+files.
dist
-'
));%0A%7D);%0A
@@ -1188,22 +1188,26 @@
ulp.src(
-'
+files.
dist
-'
)%0A .p
|
d9db864b6ede27a7aebe2622947cdde06ea14862 | Change background color of chart. | src/main/webapp/dashboard.js | src/main/webapp/dashboard.js | google.charts.load('current', {packages: ['corechart', 'line']});
// Render a chart visual on dashboard page for tracking class visits by date
function drawBasic2() {
// Set up the data table to have a class name and visits associated w/ that specific class
var data = new google.visualization.DataTable();
data.... | JavaScript | 0 | @@ -1132,162 +1132,29 @@
-backgroundColor: %7B%0A gradient: %7B%0A // Start color for gradient%0A color1: '#fcf7b6',%0A // Finish color for gradient%0A
+textStyle: %7B%0A
col
@@ -1153,185 +1153,38 @@
-
color
-2
: '
-#4ccd88',%0A // Start and end poi... |
99fb5b4bd1c75123bdcecc67f7d03129573c208a | Disable error notifications by default | src/browser/extension/options/syncOptions.js | src/browser/extension/options/syncOptions.js | import { FilterState } from '../../../app/api/filters';
let options;
let subscribers = [];
const save = (toAllTabs) => (key, value) => {
let obj = {};
obj[key] = value;
chrome.storage.sync.set(obj);
options[key] = value;
toAllTabs({ options: options });
subscribers.forEach(s => s(options));
};
const migr... | JavaScript | 0 | @@ -1060,19 +1060,20 @@
Errors:
-tru
+fals
e,%0A
|
bc20d59b1130c3e76c10c337d4f7767b9935de6d | add demo mode2 | nodejs/client.js | nodejs/client.js | var net = require('net');
var fs = require('fs'),
readline = require('readline');
var rd = readline.createInterface({
input: fs.createReadStream('./program.poi'),
// output: process.stdout,
console: false
});
var program = null;
var client = null;
var i = 0;
rd.on('line', function(line) {
var cmdStrin... | JavaScript | 0 | @@ -970,16 +970,18 @@
ted() %7B%0A
+/*
progra
@@ -989,82 +989,439 @@
=%5B25
-5,253,6, 0, 0, 0, 0, 255,
+3,1,1,0,0,0%0A,253,5,1,0,0,0%0A,253,3,0,30,0,100%0A,253,4,0,3,1,0%0A,253, 0, 0, 0, 0, 0%5D;*/%0A program=%5B253,1,1,0,0,0%0A,253,5,1,0,0,0%0A,253,3,0,30,0,100%0A,253,4,0,3,1,0%0A,253,1,2,0,0,0%0A,253,5,2,0,0,0%... |
6c4579ec5d144c47b09590503fcf8c7020535118 | tidy up | src/client/src/services/model/tradeStatus.js | src/client/src/services/model/tradeStatus.js | export default class TradeStatus {
static _pending = new TradeStatus('Pending');
static _done = new TradeStatus('Done');
static _rejected = new TradeStatus('Rejected');
name:string;
static get Pending() {
return this._pending;
}
static get Done() {
return this._done;
}
static get Rejected... | JavaScript | 0.000001 | @@ -408,50 +408,8 @@
%0A %7D
-%0A%0A toString() %7B%0A return this.name;%0A %7D
%0A%7D%0A%0A
|
43474655e0629ab304b6a00d5a62aa3a23cd8720 | Correct commits notification URL | notifications.js | notifications.js | /* Globals: configuration */
(function() {
var LOADED = false
var NOTIFICATIONS_HTML = chrome.extension.getURL('notifications.html')
var API_URL = null
var lastRequest = {
lastModified: '',
text: ''
}
getApiURL(function(url) { API_URL = url })
window.notifications = {
load: function() {
... | JavaScript | 0.000001 | @@ -3620,17 +3620,16 @@
'commit
-s
' %7D%5Bsubj
|
bc334ab84f5f037a5be755ffeeaaa9334bd7dd83 | Use .filter instead | src/Versioning.js | src/Versioning.js | let path = require('path');
let Manifest = require('./Manifest');
class Versioning {
/**
* Create a new Versioning instance.
*
* @param {object} manifest
*/
constructor(manifest) {
this.enabled = false;
this.manifest = manifest;
this.files = [];
}
/**
... | JavaScript | 0 | @@ -1119,22 +1119,21 @@
.files.f
-orEach
+ilter
(file =%3E
@@ -1137,39 +1137,17 @@
=%3E
-%7B%0A // If the
+!
updated
fil
@@ -1146,174 +1146,65 @@
ated
-
+.
file
- is exactly the same as the old%0A // one, then nothing has changed. Don't delete it.%0A if (updated.files.includ... |
38258696c664a90ffa6e19d81ad1e613070b40e2 | Increase timer value for toast | openstack_lease_it/lease_it/static/js/instances.js | openstack_lease_it/lease_it/static/js/instances.js | /*
Retrieve useful information about OpenStack
a dictionnary of instances
* Id of instance
* User
* Creation date
* Last time we see the instance
* Last lease date
* Lease expiration
*/
function instancesStatus() {
return $.getJSON("/instances", function(data) {
return data;
});
}
... | JavaScript | 0.000001 | @@ -1758,9 +1758,10 @@
-6
+10
00,
|
db4f9619a07d99def75ebca7e933a28ce2961e6a | Remove eslint-ignore and use test() instead of it() | __tests__/lib/index-test.js | __tests__/lib/index-test.js | describe('caniuseYarn', () => {
const caniuseYarn = require('../../lib'); // eslint-disable-line global-require
const shelljs = require('shelljs'); // eslint-disable-line global-require
beforeEach(() => {
shelljs.which = jest.fn();
});
it('returns true if yarn is available', () => {
shelljs.which.mo... | JavaScript | 0.000001 | @@ -1,38 +1,40 @@
-describe('caniuseYarn', () =%3E %7B%0A
+const shelljs = require('shelljs');%0A
cons
@@ -74,123 +74,41 @@
b');
- // eslint-disable-line global-require%0A const shelljs = require('shelljs'); // eslint-disable-line global-require%0A
+%0A%0Adescribe('caniuseYarn', () =%3E %7B
%0A b
@@ -157,33 +157... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.