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 |
|---|---|---|---|---|---|---|---|
271eaa9ecdb45d32f45a4ad60bae61714b85ec19 | Use Chrome instead of Firefox for Protractor tests temporarily; (Chrome does not work with Travis CI, but Firefox does not work with Selenium 2.44) | conf.js | conf.js | (function() {
'use strict';
// protractor configuration
exports.config = {
//seleniumAddress: 'http://localhost:4444/wd/hub',
specs: ['purkinje/static/js/tests/e2e/*.spec.js'],
capabilities: {
browserName: 'firefox'
}
};
})();
| JavaScript | 0 | @@ -242,40 +242,289 @@
-browserName: 'firefox'%0A %7D
+// Selenium%0A // %22Selenium 2.44 is currently not compatible with Firefox 35. %E2%80%93 rajana sekhar Feb 3 at 7:18%22%0A // http://stackoverflow.com/a/28107139%0A //browserName: 'firefox',%0A browserName:... |
c48a5839aa5cff39a69c1b8fd045bb462f33a027 | Handle new api endpoint | scripts/background.js | scripts/background.js | /*jslint indent: 2 */
/*global window: false, XMLHttpRequest: false, chrome: false, btoa: false */
"use strict";
var TogglButton = {
$user: null,
$apiUrl: "https://www.toggl.com/api",
checkUrl: function (tabId, changeInfo, tab) {
if (changeInfo.status === 'complete') {
if (/toggl\.com\/track/.test(tab... | JavaScript | 0.000005 | @@ -179,16 +179,65 @@
.com/api
+/v7%22,%0A $newApiUrl: %22https://new.toggl.com/api/v8
%22,%0A%0A ch
@@ -401,21 +401,35 @@
tchUser(
-%22/v7%22
+TogglButton.$apiUrl
);%0A
@@ -497,37 +497,54 @@
utton.fetchUser(
-%22/v8%22
+TogglButton.$newApiUrl
);%0A %7D%0A %7D
@@ -576,23 +576,19 @@
ion (api
-Versi... |
003c2952bcbe7a90642fa249f1d875c5303bc341 | Update WebTundraModel.js | src/WebTundraModel.js | src/WebTundraModel.js | "use strict";
// For conditions of distribution and use, see copyright notice in LICENSE
/*
* @author Erno Kuusela
* @author Tapani Jamsa
*/
/* jslint browser: true, globalstrict: true, devel: true, debug: true */
/* global THREE, THREEx, signals */
/* global WebSocketClient, Scene, SyncManager, EC_Mesh, EC_Pla... | JavaScript | 0 | @@ -462,12 +462,14 @@
y =
-562;
+null;%0A
%0Afun
|
501a85b1baa564f37c056c3411831865ab29de9a | Fix regex | entry/index.js | entry/index.js | module.exports = function (context, req) {
var https = require('https');
var input = JSON.stringify(req.body);
var userquery = input.split('&')[8].split('=')[1];
var callback = input.split('&')[9].split('=')[1];
var username = input.split('&')[6].split('=')[1];
function getMetar(icaocode)... | JavaScript | 0.999981 | @@ -1298,59 +1298,96 @@
h);%0A
- context.log('%25s', userquery.test('/%5E%5Ba-zA-Z%5D+$'
+%0A var regexpattern = /%5E%5Ba-zA-Z%5D+$/;%0A context.log('%25s', regexpattern.test(userquery
));%0A
@@ -1451,37 +1451,35 @@
&&
-userquery
+regexpattern
.test(
-'/%5E%5Ba-zA-Z%5D+$'
+userquery
)) %7B
|
1fd83587675006b9af19b4754bc7eba9ecc33053 | Update character | commit.js | commit.js | var fs = require('fs');
var child_process = require('child_process')
var max_sleep = 300
if ( process.argv[ 2 ] && process.argv[ 3 ] ) {
var inFile = process.argv[ 2 ]
var outFile = process.argv[ 3 ]
if (process.argv [ 4 ]) max_sleep = process.argv [ 4 ]
console.info("Writing from %s to %s, with up to %s secon... | JavaScript | 0 | @@ -791,8 +791,9 @@
nter++)%0A
+
|
bf6153dc15bd73debb439ecc43eb77a503b6ebb4 | Update demo to start from the top | demo/demo.js | demo/demo.js | var canvas = Confetti.createCanvas(
document.querySelector('div'),
document.querySelector('canvas')
);
var config = {
angle: 0.01,
tiltAngle: 0.1,
draw: draw,
updatePosition: updatePosition,
updateState: updateState
};
var particles = _.range(0, Confetti.DEFAULT_NUM).map(function () {
return Confetti.... | JavaScript | 0 | @@ -378,45 +378,9 @@
y:
-Confetti.randomFrom(0, canvas.height)
+0
,%0A
|
df10e560f210fea442d5bab692000276f815c984 | Use middleware exposed from promBundle | config/express.js | config/express.js | const log = require('../app/lib/logger');
const express = require('express');
const helmet = require('helmet');
const cookieParser = require('cookie-parser');
const bodyParser = require('body-parser');
const compression = require('compression');
const nunjucks = require('nunjucks');
const router = require('./routes');... | JavaScript | 0 | @@ -663,19 +663,8 @@
le')
-.middleware
;%0Aco
@@ -3015,16 +3015,27 @@
omBundle
+.middleware
);%0A app
|
8a6bee189f7b0b89adbc87dc905c8a5d257481f3 | Update RaidEmbed.js | src/embeds/RaidEmbed.js | src/embeds/RaidEmbed.js | 'use strict';
const BaseEmbed = require('./BaseEmbed.js');
const RaidStat = require('../resources/RaidStat.js');
/**
* Generates simaris embeds
*/
class RaidStatEmbed extends BaseEmbed {
/**
* @param {Genesis} bot - An instance of Genesis
* @param {Simaris} userStats - User raid stat json
* @param {strin... | JavaScript | 0 | @@ -345,16 +345,71 @@
s embed%0A
+ * @param %7Bstring%7D platform - Platform for the query%0A
*/%0A
@@ -441,16 +441,26 @@
s, query
+, platform
) %7B%0A
@@ -551,16 +551,86 @@
https://
+$%7Bplatform.toLowerCase() !== 'pc' ? %60$%7Bplatform.toLowerCase()%7D.%60 : ''%7D
trials.w
|
07554440890d675a55d03e04d646e4f064cc8d60 | Update app.js | js/app.js | js/app.js | /* doesn't work
$(document).ready(function() {
$('.bar2').click(function() {
$(".tablez").animate({
left: "-500px"
}, 200);
});
});// end ready
*/
// Define spreadsheet URL.
//Sales Floor
var mySpreadsheet = 'https://docs.google.com/spreadsheet/ccc?key=11x3_5BinmTr4sxeH4TiQrgvwp6OPKmERSOSu... | JavaScript | 0.000002 | @@ -2339,16 +2339,21 @@
);%0A */%0A
+ /*%0A
$('#bar1
@@ -2443,11 +2443,13 @@
0);%0A%7D);%0A
+*/
%0A%0A%0A
|
67f1f9a29a9081e142944f7feeefafaa77fbc3bc | Use sign instead of round | js/permutation.js | js/permutation.js | (function($){
$.permutation = function(){
return new Permutation($.toArray(arguments));
};
var Permutation = $.Permutation = function(image){
this.image = image;
};
Permutation.prototype.actOn = function(element){
return this.image[element];
};
Permutation.prototype.m... | JavaScript | 0 | @@ -987,13 +987,12 @@
ath.
-round
+sign
(pro
|
d222c26c21e8b8af108cc51b5cb15b61798c2b43 | Update app.js | js/app.js | js/app.js | var nodeList = document.getElementsByClassName('draggable');
for(var i=0;i<nodeList.length;i++) {
var obj = nodeList[i];
obj.addEventListener('touchmove', function(event) {
var touch = event.targetTouches[0];
var izq = document.getElementById('mano_izq');
var ancho = obj.offsetWidth;
v... | JavaScript | 0.000002 | @@ -271,16 +271,52 @@
_izq');%0A
+ var izqpost = izq.offsetLeft;%0A
va
@@ -509,13 +509,23 @@
-if ((
+var posicion =
touc
@@ -545,37 +545,40 @@
o/2)
- + 'px')
+;%0A if (posicion
===
-(
izq
-.offsetLeft)
+post
) %7B%0A
|
cb071aa8875d93420118dd580f2f85776ff7b6e2 | Update bst.js | js/bst.js | js/bst.js | $(document).ready(function() {
$(".commentlist li").addClass("panel panel-default");
$(".comment-reply-link").addClass("btn btn-default");
/*
HOVERNAV
Navbar dropdown on hover.
Delete this segment if you don't want it, and delete the corresponding CSS in bst.css
Uses jQuery Media Query - see http://www.site... | JavaScript | 0.000001 | @@ -420,26 +420,25 @@
matches) %7B%0A%09
-
+%09
$('ul.navbar
@@ -482,18 +482,17 @@
else %7B%0A%09
-
+%09
$('ul.na
@@ -623,135 +623,8 @@
8px%0A
-%09if (matchMedia) %7B%0A%09 var mq = window.matchMedia('(min-width: 768px)');%0A%09 mq.addListener(WidthChange);%0A%09 WidthChange(mq);%0A%09%7D%0A
%09fun
@@ -793... |
ea1bf99d040b71328a7cee5da04c1f72fdbee3e9 | Add comments to explain math | src/actions/screen.js | src/actions/screen.js | import Vector from '../geometry/vector'
import {
RESIZE_WINDOW,
ZOOM_WINDOW,
PAN_WINDOW_START,
PAN_WINDOW,
} from './types'
export function resize(size) {
return (dispatch, getState) => {
let { screen: { screen, viewport } } = getState()
let viewportDx = size.sub(screen.size).div(screen.size).mult(vi... | JavaScript | 0 | @@ -238,32 +238,98 @@
%7D = getState()%0A
+ // 1/2 * viewport.size * ((size - screen.size) / screen.size)%0A
let viewport
@@ -933,32 +933,79 @@
iv(screen.size)%0A
+ // (dZoom * viewport.size) - viewport.size%0A
let viewport
|
bd93a7f15ff94dada82cdb96f72b2eb24e4840a0 | Make frontend expect `data_url` instead of `s3_url` (#30) | src/actions/stream.js | src/actions/stream.js | import { CALL_API } from 'redux-api-middleware'
import { reset as resetForm } from 'redux-form'
import {
fetch,
createResource,
performActionOnResource
} from './index'
export function loadStreams () {
return fetch({
url: 'streams',
types: [ 'STREAMS_REQUEST', 'STREAMS_SUCCESS', 'STREAMS_FAILURE' ]
... | JavaScript | 0.00001 | @@ -866,14 +866,15 @@
Id%5D.
-s3Path
+dataUrl
%0A%0A
|
996978eff38b1d5d1a07202dc3326a12cabf96d7 | update match pattern | scripts/background.js | scripts/background.js | // Copyright (c) 2011 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// When the extension is installed or upgraded ...
chrome.runtime.onInstalled.addListener(function() {
// Replace all rules ...
chrome.declara... | JavaScript | 0 | @@ -731,16 +731,207 @@
tps'%5D %7D%0A
+ %7D),%0A new chrome.declarativeContent.PageStateMatcher(%7B%0A pageUrl: %7B hostContains: %22.assetic.net%22, urlContains: 'complex', schemes: %5B'https'%5D %7D%0A
@@ -941,16 +941,16 @@
%7D)%0A
-
@@ -1105... |
397639b27e8da3cca05a93a21d4fbb3ac1db3340 | Fix render on page reload | usability/python-markdown.js | usability/python-markdown.js | // Allow Python-code in markdown cells
// Encapsulate using {{...}}
// - You can also return html or markdown from your Python code
// - You can embed images, however they will be sanitized on reload.
define([
'base/js/namespace',
'jquery',
'notebook/js/cell',
'base/js/security',
'notebook/js/mathj... | JavaScript | 0.000001 | @@ -509,16 +509,96 @@
trict%22;%0A
+ var _on_reload = true; /* make sure cells with variables render on reload */
%0A var
@@ -1110,50 +1110,126 @@
irty
-: execute %0A b) notebook clean
+ or variable not stored in metadata: evaluate variable%0A b) notebook clean and variable stored in ... |
994a322d4cdee3f8b06f2723cfd35ebe7d9f47f5 | change cordova require to normal require | scripts/ios/helper.js | scripts/ios/helper.js | var fs = require("fs");
var path = require("path");
var utilities = require("../lib/utilities");
/**
* This is used as the display text for the build phase block in XCode as well as the
* inline comments inside of the .pbxproj file for the build script phase block.
*/
var comment = "\"Crashlytics\"";
module.export... | JavaScript | 0 | @@ -1168,35 +1168,14 @@
e =
-context.requireCordovaModul
+requir
e(%22x
@@ -3201,35 +3201,14 @@
e =
-context.requireCordovaModul
+requir
e(%22x
|
62c9842f909757a9c7fb9a4875baf2405e2911a6 | add conversion code to apparent temp [Finishes #137645715] | scripts/javascript.js | scripts/javascript.js | function geoLocation() {
var output = document.getElementById("out");
if (!navigator.geolocation) {
output.innerHTML = "<p>Geolocation is not supported by your browser</p>";
return;
}
function success(position) {
var latitude = position.coords.latitude;
var longitude = ... | JavaScript | 0 | @@ -550,47 +550,20 @@
key=
-AIzaSyAZch_gAq-6Ja3fUQ8sXStIhyB_dJ0mSgU
+YOUR-API-KEY
', f
@@ -965,40 +965,20 @@
ast/
-61f104c5d563f5c8aa29eca3beea2bde
+YOUR-API-KEY
/' +
|
948e652270f814019bd18c5708a5e4ab09e6b916 | Fix image fetch task restart | lib/app/message_images_fetch.js | lib/app/message_images_fetch.js | // Create worker to fetch images from remote servers and cache their size
//
// params:
//
// - task_name (String)
// - find (Function => Promise) - `function (id)`
// - rebuild (Function => Promise) - `function (id)`
//
'use strict';
const _ = require('lodash');
const $ = require('nodeca.core/l... | JavaScript | 0.000004 | @@ -497,107 +497,8 @@
;%0A%0A%0A
-// a number of times the task can be re-created if image fetch errors out%0Aconst MAX_RETRIES = 2;%0A%0A%0A
modu
@@ -819,24 +819,55 @@
* 60 * 1000,
+%0A retryDelay: 5 * 60 * 1000,
%0A%0A timeou
@@ -874,24 +874,41 @@
t: 120000,%0A%0A
+ retries: 3,%0A%0A
taskID(m
@@ -9... |
052672c7f00c4334038301f65edff04e0c96a8ca | fix dom table building | js/dom.js | js/dom.js | function displayEc2DataTable(data) {
getEc2DataTableBody().innerHTML += buildEc2DataTable(data);
// let it be sortable :)
Sortable.init();
showAwsQueryResults();
}
function resetEc2DataTable() {
hideAwsQueryResults();
getEc2DataTableBody().innerHTML = "";
}
// TODO: Make this prettier :)
function buildEc2... | JavaScript | 0.000001 | @@ -398,16 +398,16 @@
var
-i
+z
= 0;
-i
+z
%3C d
@@ -417,16 +417,134 @@
Len;
+ z++) %7B%0A var regionData = data%5Bz%5D%5B%22data%22%5D;%0A var regionLen = regionData.length;%0A for(var i = 0; i %3C regionLen;
i++) %7B%0A
@@ -535,24 +535,26 @@
Len; i++) %7B%0A
+
htmlSnip
@@ -581,25 +581... |
2e4205e568c5c407bdaeed697c29ff55f60feb09 | Update resourcemap.js | js/resourcemap.js | js/resourcemap.js | var map;
var addressBar;
function init() {
var mapOptions = {
center: new google.maps.LatLng(43.020054,-83.693008),
zoom: 9,
mapTypeId: 'roadmap',
};
map = new google.maps.Map(document.getElementById('map-canvas'), mapOptions);
// a new Info Window is created
addressBa... | JavaScript | 0.000001 | @@ -1937,16 +1937,23 @@
img/GMM/
+office
space.pn
|
440def810dc8cb67eda78c5e0b23b3030fd9114e | Remove unused code segment | core/main.js | core/main.js | /**
* Entry Point
* Belongs to Decentraleyes.
*
* @author Thomas Rientjes
* @since 2016-04-04
* @license MPL-2.0
*
* 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://moz... | JavaScript | 0.000002 | @@ -2064,112 +2064,8 @@
);%0A%0A
-chrome.runtime.getPlatformInfo(function (information) %7B%0A main.operatingSystem = information.os;%0A%7D);%0A%0A
wrap
|
66ada5fd873fcda98503772977775f68415aec0c | Update helpers.js | src/es/utils/helpers.js | src/es/utils/helpers.js | imports {, } from './routines/extras.js';
export const Helpers = {
isEqual(){
}
};
| JavaScript | 0.000001 | @@ -3,12 +3,15 @@
port
-s
%7B
-,
+ wind
%7D f
@@ -30,13 +30,13 @@
nes/
-extra
+basic
s.js
@@ -72,16 +72,20 @@
+
+
isEqual(
)%7B%0A
@@ -84,14 +84,996 @@
ual(
-)%7B%0A %0A
+former, latter) %7B%0A if (former === latter) %7B%0A return true;%0A ... |
34f3674e9d2d9ea7fa2e61835be67ea1a74438c4 | Remove typings for `/es` build (#14422) | scripts/copy-files.js | scripts/copy-files.js | /* eslint-disable no-console */
const path = require('path');
const fse = require('fs-extra');
const glob = require('glob');
const packagePath = process.cwd();
const buildPath = path.join(packagePath, './build');
const srcPath = path.join(packagePath, './src');
async function includeFileInBuild(file) {
const source... | JavaScript | 0 | @@ -3949,36 +3949,16 @@
await
-Promise.all(%5B%0A
typescri
@@ -4001,94 +4001,8 @@
h %7D)
-,%0A typescriptCopy(%7B from: srcPath, to: path.resolve(buildPath, './es') %7D),%0A %5D)
;%0A%0A
|
28df4f56975f4675bbff7c73d67f9eebb86cc214 | Fix Keystone adminUI being broken | admin/client/App/screens/Item/components/EditFormHeader.js | admin/client/App/screens/Item/components/EditFormHeader.js | import React from 'react';
import ReactDOM from 'react-dom';
import Toolbar from './Toolbar';
import ToolbarSection from './ToolbarSection';
import { Button, FormIconField, FormInput, ResponsiveText } from 'elemental';
import { Link } from 'react-router';
var Header = React.createClass({
displayName: 'EditFormHeader'... | JavaScript | 0 | @@ -113,24 +113,32 @@
ion from './
+Toolbar/
ToolbarSecti
|
df4117fb7b72e7704e6b7eb56190e49ba1fe311a | Add --copy-files flag | scripts/prepublish.js | scripts/prepublish.js | const path = require('path');
const shell = require('shelljs');
const chalk = require('chalk');
const babel = ['node_modules', '.bin', 'babel'].join(path.sep);
require('./ver');
const args = [
'--ignore tests,__tests__,stories,story.jsx,story.js',
'--plugins "transform-runtime"',
'./src --out-dir ./dist',
].jo... | JavaScript | 0.000001 | @@ -103,17 +103,26 @@
babel =
-%5B
+path.join(
'node_mo
@@ -148,23 +148,8 @@
bel'
-%5D.join(path.sep
);%0A%0A
@@ -303,16 +303,34 @@
/dist',%0A
+ '--copy-files',%0A
%5D.join('
|
c0efb8264a62aa31aaa46867a823c43d465d442f | Add precipChance variable [#137759957] | scripts/javascript.js | scripts/javascript.js | function geoLocation() {
var output = document.getElementById("out");
if (!navigator.geolocation) {
output.innerHTML = "<p>Geolocation is not supported by your browser</p>";
return;
}
function success(position) {
var latitude = position.coords.latitude;
var longitude = ... | JavaScript | 0 | @@ -1571,16 +1571,99 @@
summary;
+%0A var precipChance = (data.currently.precipProbability * 100) + %22%25%22;
%0A%0A
@@ -1918,16 +1918,34 @@
%7D%0A%0A
+ %0A%0A
%0A
@@ -2109,16 +2109,16 @@
mpFeel;%0A
-
@@ -2167,16 +2167,68 @@
elsius;%0A
+ wi... |
9525e384abe9c4c8b1e7e906a5b72765d174b2cf | add missing require | cron.js | cron.js |
var skiff = require('./lib/skiff'), // this must be required first
rollbar = skiff.rollbar,
sails = skiff.sails,
Digest = require('./lib/community/digest');
require('colors');
var intervals = {
daily: function() {
sails.log.debug('noop!');
},
hourly: function() {
var now = moment.tz('America/Lo... | JavaScript | 0.000045 | @@ -61,16 +61,55 @@
d first%0A
+ moment = require('moment-timezone'),%0A
rollba
|
7998023e581ce258f793db29f58c99141c95bef6 | Add comments. | lib/collections/forceLoading.js | lib/collections/forceLoading.js | if (Meteor.isServer) {
Meteor.publish('forceLoading', function(){
var self = this; // Protect our value of this.
Meteor.setTimeout(function() {
self.ready();
}, 1000);
});
} else {
// Subscriptions
}
| JavaScript | 0 | @@ -1,8 +1,182 @@
+/***%0A * lib/collections/forceLoading.js%0A *%0A * The %22collection%22 only exists to test the display of a loading page by%0A * Iron Router, it should not be used in production.%0A */%0A%0A
if (Mete
|
a0e8650f5aa1c2f8f9a0c4c9c7a2062636d7224c | Update img.js | js/img.js | js/img.js | (function() {
"use strict";
var states = {
MAIN: 0,
VIEW: 1
};
var sequenceTypes = {
ALPHABETICAL: 0,
NUMERIC: 1
};
var casings = {
LOWERCASE: 0,
UPPERCASE: 1,
MIXED: 2
};
var state = null;
var baseUrl = null;
var sequences = [];
function byId(input) {
ret... | JavaScript | 0.000001 | @@ -1714,18 +1714,20 @@
nces%22).a
-dd
+ppen
Child(el
|
e4b3b0ad10b4748be1600f31a9082e7dad9520a5 | make "abs" example a little more "fun" :p | example/abs.js | example/abs.js |
/**
* This example creates an ffi.Callback from the "Math.abs()" JavaScript function
* then creates a ffi.ForeignFunction from that callback function pointer.
*
* The result is basically the same as calling "Math.abs()" directly, haha!
*
* This example should basically just run forever, in an endless loop.
* Th... | JavaScript | 0.000025 | @@ -792,20 +792,28 @@
ual(
-1234
+Math.abs(-i)
, func(-
1234
@@ -812,12 +812,9 @@
nc(-
-1234
+i
))%0A
|
bd1a455580cef87759abcc4a7a1cd952ae4c71c7 | Fix onPlaying event name | example/app.js | example/app.js | /* global document */
import React from 'react';
import ReactDOM from 'react-dom';
import YouTube from '../';
const videos = [
{ id: 'ZuuVjuLNvFY', name: 'JUNNY - kontra (Feat. Lil Gimch, Keeflow)' },
{ id: 'PYE7jXNjFWw', name: 'T W L V - Follow' },
{ id: 'ld8ugY47cps', name: 'SLCHLD - I can\'t love you anymore'... | JavaScript | 0.000029 | @@ -3127,16 +3127,19 @@
onPlay
+ing
=%7Bthis.h
|
76522ddb4fdc6fbfcfa1cf5e1c72fec317c06a57 | remove useless space | js/map.js | js/map.js | var map = {
makeFeatures: {
section: function(json) {
var makeStopTimesMarker = function() {
var stopTimes = json['stop_date_times'];
var markers = []
if (stopTimes) {
stopTimes.forEach(function(st) {
mar... | JavaScript | 0.002559 | @@ -780,17 +780,16 @@
arkers;%0A
-%0A
|
72b0f428198903e1b90b42950e41ab72de190e03 | Refactor filter validator | validator/FilterValidator.js | validator/FilterValidator.js | /**
* @copyright Copyright (c) 2019 Maxim Khorin <maksimovichu@gmail.com>
*/
'use strict';
const Base = require('./Validator');
module.exports = class FilterValidator extends Base {
static async filterSplit (value, attr, model, validator) {
return StringHelper.split(value, validator.separator);
}
... | JavaScript | 0.000001 | @@ -475,22 +475,22 @@
-filter
+method
: null,%0A
@@ -687,30 +687,30 @@
let
-filter
+method
= this.
filter;%0A
@@ -701,22 +701,22 @@
= this.
-filter
+method
;%0A
@@ -721,22 +721,22 @@
if (
-filter
+method
=== nul
@@ -769,22 +769,22 @@
Error('
-Filter
+Method
propert
@@ -829,22 +82... |
1ee13fc1c0b7356967bc8066aab497866ab612e1 | Update app.js | desio/app.js | desio/app.js | // Code goes here
var myApp = angular.module('myApp', ['angularUtils.directives.dirPagination']);
function MyController($scope, $http) {
$scope.currentPage = 1;
$scope.pageSize = 20;
$scope.items = [];
$http.get("https://raw.githubusercontent.com/infocitta/dataset/master/desio/livello2.json")
.then(funct... | JavaScript | 0.000002 | @@ -221,73 +221,8 @@
et(%22
-https://raw.githubusercontent.com/infocitta/dataset/master/desio/
live
|
55fb2dfa71f38ab3c085dcdf9b8554874aa64342 | Update makeVisualisations.js | Refugees/javascripts/makeVisualisations.js | Refugees/javascripts/makeVisualisations.js | /*Naam: Sanne Berendschot
Studentnummer: 10269290
Minor Programmeren, Programmeerproject*/
// load data
queue()
.defer(d3.tsv, "Dataset Origin goed 23 juni.tsv")
.defer(d3.tsv, "Dataset Asylum goed 23 juni.tsv")
.defer(d3.tsv, "Data Population Worldbank.tsv")
.defer(d3.json, "dataBarcha... | JavaScript | 0 | @@ -136,156 +136,350 @@
v, %22
-Dataset Origin goed 23 juni.tsv%22) %0D%0A .defer(d3.tsv, %22Dataset Asylum goed 23 juni.tsv%22)%0D%0A .defer(d3.tsv, %22Data Population Worldbank
+https://raw.githubusercontent.com/smeber/Programmeerproject/master/Refugees/data/dataOrigin.tsv%22) %0D%0A .defer(d3.tsv, %22h... |
94cf46d797a6555543ffe90208e1bf1af3f14f16 | fix add single quote | js/nfc.js | js/nfc.js | 'use strict';
var webSocket = new WebSocket('ws://colocolo.mybluemix.net/ws/nfc');
var nfcList = {
'4ffffff97ffffff80ffffff82ffffffeb2bffffff80': { index: 1, clean: 0 },
'4ffffff97ffffff80ffffff82ffffffeb2bffffff81': { index: 2, clean: 0 },
'4ffffff97ffffff80ffffff82ffffffeb2bffffff82': { index: 3, clean: ... | JavaScript | 0.000001 | @@ -1743,21 +1743,23 @@
st%5Bkey%5D%5B
+'
index
+'
%5D;%0A
@@ -1878,8 +1878,9 @@
%7D);%0A%7D);
+%0A
|
e99fbcc2bfdd1d3d45652f191a91c58bcbab6d66 | Make it .html to prevent confusion | countdown.js | countdown.js | $(document).ready(function() {
var endTime = new Date();
endTime.setFullYear(2014);
endTime.setMonth(0);
endTime.setDate(1);
endTime.setHours(0);
endTime.setMinutes(0);
var id = setInterval(function() {
var startTime = new Date();
var msec = endTime.getTime() - startTime.getTime();
var sec = Math.fl... | JavaScript | 0.000019 | @@ -703,12 +703,12 @@
r').
-text
+html
(day
@@ -761,8 +761,9 @@
00);%0A%7D);
+%0A
|
b9180eb6c7bcfa8a0d8386d5cb6a6f0a41709bf3 | Update contact_me.js | js/contact_me.js | js/contact_me.js | $(function() {
$("#contactForm input,#contactForm textarea").jqBootstrapValidation({
preventSubmit: true,
submitError: function($form, event, errors) {
// additional error messages or events
},
submitSuccess: function($form, event) {
// Prevent spam click and... | JavaScript | 0 | @@ -984,17 +984,8 @@
l: %22
-././mail/
cont
|
9743308d63f5d8cd7a32256222d5a54d481d199f | add a test of the camera image to view locally in the html | js/testplugins.js | js/testplugins.js | /**
* Created with IntelliJ IDEA.
* User: tparmer
* Date: 11/21/13
* Time: 3:10 AM
* To change this template use File | Settings | File Templates.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for ad... | JavaScript | 0 | @@ -5564,32 +5564,34 @@
) %7B%0A
+//
console.log('suc
@@ -5630,17 +5630,16 @@
tElement
-s
ById('te
|
8b96ef847e4b426dded0e0b6a34156fca67911c5 | Drop unused isPublic selector for transcripts. | js/transcripts.js | js/transcripts.js | 'use strict';
require('./base');
// import controller for the transcript view actions
var controller = require('./controllers/transcripts');
const connector = require('./connector');
const createStore = require('./store');
import '../css/index.css'; // Root styles file (reset, fonts, globals)
const Transcripts = requi... | JavaScript | 0 | @@ -357,137 +357,8 @@
e');
-%0Avar isPublicSelector = require('./isPublicSelector');%0A%0Avar setPublic = state =%3E (%7B...state, isPublic: isPublicSelector(state)%7D);
%0A%0Ava
@@ -462,24 +462,13 @@
=%3E
-setPublic(
state
-)
;%0A%0A/
|
7e64ff72f47a50276ac4fd9281e2091712ffec7e | Update contact_me.js | js/contact_me.js | js/contact_me.js | $(function() {
$("#contactForm input,#contactForm textarea").jqBootstrapValidation({
preventSubmit: true,
submitError: function($form, event, errors) {
// additional error messages or events
},
submitSuccess: function($form, event) {
// Prevent spam click and... | JavaScript | 0 | @@ -1224,32 +1224,66 @@
%7D,%0A
+ dataType: 'html',%0A
|
690ae44d9dbe02d2d3a147663435ebbd1dc1b00f | Update locales.js | config/locales.js | config/locales.js | # Current language.
var tech_docs_language = 'pt-br';
var tech_docs_l18n = {};
tech_docs_l18n['en'] = {
back_to_index: 'back to index',
stage_number: 'Stage {number}',
action_number: '{number} - '
}
tech_docs_l18n['pt-br'] = {
back_to_index: 'voltar ao índice',
stage_number: '{number}ª Etapa',
action_nu... | JavaScript | 0.000001 | @@ -1,5 +1,6 @@
-#
+//
Cur
|
9944b13b498bc13ceac622cccad46d0444d43dd8 | Fix related to support for compressed CSS | js/rem.js | js/rem.js | (function (window, undefined) {
// test for REM unit support
var cssremunit = function() {
var div = document.createElement( 'div' );
div.style.cssText = 'font-size: 1rem;';
return (/rem/).test(div.style.fontSize);
},
// filter returned link nodes for stylesheets
isSt... | JavaScript | 0 | @@ -1292,17 +1292,17 @@
,.'%22*()%5D
-+
+*
%5C%7D/g, //
|
8be622245c5809ddcc7a78d117d9503a76bf6d4b | Update start-stop.js | scripts/start-stop.js | scripts/start-stop.js | //@auth @req(action, envName)
var a = action + '', c = jelastic.env.control, e = envName, s = session, r, status;
status = c.GetEnvInfo(e, s).env.status;
switch (a) {
case 'start':
if (status == 2 || status ==4) {
r = c.StartEnv(e, s);
}
break;
case 'stop':
if (s... | JavaScript | 0.000001 | @@ -533,12 +533,82 @@
esult: 0
+,%0A message: %22Unable to %22 + a + %22 environemnt, status is %22+ status,
%0A%7D;%0A
|
96b281a49a3fbfee530f914b019f53f1fd76d2c4 | fix initurl value | js/rtl.js | js/rtl.js |
(function(){
var initUrl = 'http://localhost/rtl/initcontent.md';
$(document).ready(function(){
$('body').append('<div id="content"></div>');
$.get( initUrl)
.done(function( data ) {
$('#box').val(data);
});
var opts = {
onInitialize : true
};
$('#box').autogrow(op... | JavaScript | 0.000001 | @@ -36,21 +36,31 @@
p://
-localhost
+dariubs.github.io
/rtl
+md
/ini
|
a9d36bbf4e4c160508fbe8e2800e9e8e0c80263f | remove obsolete TODO notice | lib/fetching/sourceToChannel.js | lib/fetching/sourceToChannel.js | /**
* A set of helpful utility functions for converting
* between Aggie Sources and Downstream Channels.
*/
const { builtin } = require('downstream');
const Source = require('../../models/source');
const _ = require('../../models/credentials'); // registers the Credentials schema
const downstream = require('./downs... | JavaScript | 0.000001 | @@ -1905,59 +1905,8 @@
tags
- // TODO TODO TODO get tags & add them into Reports
%0A
|
2c570f270292d9e9609a51c7c141f84f37c3d6de | Fix roomId missing from login response if admin | server/User/router.js | server/User/router.js | const db = require('sqlite')
const squel = require('squel')
const jwtSign = require('jsonwebtoken').sign
const bcrypt = require('../lib/bcrypt')
const KoaRouter = require('koa-router')
const router = KoaRouter({ prefix: '/api' })
const Prefs = require('../Prefs')
// login
router.post('/login', async (ctx, next) => {
... | JavaScript | 0.000001 | @@ -5442,25 +5442,27 @@
//
-validate roomId (
+roomId is required
if n
@@ -5476,16 +5476,26 @@
dmin
-)
%0A if (
+!roomId &&
!use
@@ -5511,29 +5511,8 @@
) %7B%0A
- if (!roomId) %7B%0A
@@ -5548,28 +5548,63 @@
a room')%0A
-
%7D%0A
+%0A // validate roomId%0A if (roomId) %7B
%0A const q
|
ec79526867e5364aa93e6c37bd20e743eac84b83 | Remove undefined from constructor | js/scd.js | js/scd.js | var Scd = function(videoEl, options, undefined) {
// Public properties.
// Contains detected scene changes timecodes.
this.sceneTimecodes = [];
// Private properties.
var that = this;
var document = window.document;
var Math = window.Math;
// The width and height at which the frames wi... | JavaScript | 0.000007 | @@ -32,19 +32,8 @@
ions
-, undefined
) %7B%0A
|
1a0d634b934176e861a79db5f96115b4ef50afa1 | comment removed. | views/static/scripts/news.js | views/static/scripts/news.js | $(function() {
// News DOM elements (<li>)
var dom_news = document.querySelectorAll('.news[data-id][data-can-edit="1"]'),
// cache for news informations
news = {};
// if there is no news, exit
if (!dom_news.length) { return; }
// fill the news object
[].forEach.call(dom_news, fun... | JavaScript | 0 | @@ -2131,85 +2131,8 @@
ews%0A
- // TODO: display the button only if the user has the right to add a news%0A
|
1aa23a9556b1856addddf66dd3bd986d1a10293f | Update get-private-persons-name.js | lib/get-private-persons-name.js | lib/get-private-persons-name.js | 'use strict'
function generateMetadataPrivatePersonName (options) {
if (!options) {
throw new Error('Missing required input: options')
}
if (!options.name && !options.personalIdNumber) {
throw new Error('Missing required input: options.name or options.personalIdNumber')
}
var meta = {
'clientSer... | JavaScript | 0.000002 | @@ -453,16 +453,17 @@
Persons'
+,
%0A 'da
|
c0c855b5e9ae38e26e22773706421890c694bdcf | Add param and use explicit return statements | scripts/wee-screen.js | scripts/wee-screen.js | import { $exec } from 'core/core';
import { $toArray } from 'core/types';
import { _win, _html } from 'core/variables';
let events = [];
let id = 0;
let bound;
let current;
/**
* Bind individual rule
*
* @private
* @param {object} conf - breakpoint rules
* @param {Array} [conf.args] - callback arguments
* @para... | JavaScript | 0.000001 | @@ -2031,16 +2031,74 @@
t rules%0A
+ * @param %7Bstring%7D %5Bnamespace%5D - namespace for map object%0A
*/%0Afunc
@@ -2290,24 +2290,25 @@
current)) %7B%0A
+%0A
%09%09if (namesp
@@ -2338,24 +2338,37 @@
ilter(obj =%3E
+ %7B%0A%09%09%09%09return
obj.namespa
@@ -2379,24 +2379,30 @@
== namespace
+;%0A%09%09%09%7D
... |
de3f0534097183fc95277a18e79e478d36062c84 | Fix minor issue with validation error text | lib/helpers/validate-account.js | lib/helpers/validate-account.js | 'use strict';
var async = require('async');
var getRequiredRegistrationFields = require('./get-required-registration-fields');
/**
* @private
* @callback validateAccountCallback
* @param {Error[]} errors - An array of Account validation errors (if there
* are any). Will be null if no errors are present and the... | JavaScript | 0.000001 | @@ -1756,21 +1756,20 @@
%7C field.
-label
+name
) + ' re
|
1c345e4b05628325a59989f7f382389aa780e651 | use heroku url if available | server/http-common.js | server/http-common.js | const axios = require('axios')
var apiUri = process.env.HEROKU_URL || "http://localhost:8000/";
const HTTP = axios.create({
// baseURL: 'http://localhost:8000/'
baseURL: apiUri
})
module.exports = HTTP
| JavaScript | 0 | @@ -28,19 +28,20 @@
s')%0A
-%0Avar
+const
apiU
-ri
+RL
= p
@@ -65,17 +65,17 @@
_URL %7C%7C
-%22
+'
http://l
@@ -92,10 +92,9 @@
000/
-%22;
+'
%0A%0Aco
@@ -124,11 +124,8 @@
(%7B%0A
- //
bas
@@ -134,50 +134,14 @@
RL:
-'http://localhost:8000/'%0A baseURL: apiUri
+apiURL
%0A%7D)%0A
|
d22f79b0dc63d70417bd48354ef6ebd70d09f8a6 | Fix for UserSchema definition roles attribute - String -> Array | server/models/user.js | server/models/user.js | 'use strict';
/**
* Module dependencies.
*/
var mongoose = require('mongoose'),
Schema = mongoose.Schema,
crypto = require('crypto');
/**
* User Schema
*/
var UserSchema = new Schema({
name: {
type: String,
required: true
},
email: String,
username: {
type: String,
... | JavaScript | 0 | @@ -356,9 +356,8 @@
es:
-%5B
%7B%0A
@@ -360,38 +360,37 @@
%7B%0A type:
-String
+Array
,%0A defaul
@@ -392,16 +392,17 @@
efault:
+%5B
'authent
@@ -412,15 +412,15 @@
ted'
+%5D
%0A %7D
-%5D
,%0A
@@ -3513,9 +3513,8 @@
Schema);
-%0A
|
9effd78a9f761870c181668a8677b3ad90de0013 | Update banner: v4.0.0 | dist/hunt.js | dist/hunt.js | /* Hunt v3.0.2 - 2017 Jeremias Menichelli - MIT License */
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global.Hunt = factory());
}(this, (function () { 'use strict';
var... | JavaScript | 0.000001 | @@ -6,13 +6,13 @@
nt v
-3.0.2
+4.0.0
- 2
|
7817aa38f64350a35386babb72283546ce026c29 | Fix for actual windows user agent string | lib/middleware/ext/useragent.js | lib/middleware/ext/useragent.js | /*!
* Module dependencies.
*/
var useragent = require('useragent');
/**
* Parse User-Agent for Cordova Platform.
*
* Options:
*
* - `ua` {String} is the server request user-agent header.
* - `[jsUA]` {String} is the optional user-agent from the client-side JS.
*
* Returns:
*
* - {Object} to describe... | JavaScript | 0.00001 | @@ -817,20 +817,16 @@
s: /
-Windows Phon
+IE Mobil
e/i.
|
4ec60e035b6f9fe2390d8d533d51e9b6115a2fce | remove explicit port bind | lib/navdata/UdpNavdataStream.js | lib/navdata/UdpNavdataStream.js | var Stream = require('stream').Stream;
var util = require('util');
var dgram = require('dgram');
var constants = require('../constants');
var parseNavdata = require('./parseNavdata');
module.exports = UdpNavdataStream;
util.inherits(UdpNavdataStream, Stream);
function UdpNavdataStream(options) ... | JavaScript | 0.000001 | @@ -1111,26 +1111,16 @@
et.bind(
-this._port
);%0A thi
|
4d5ffe1efc9846cd41ba3c645dbeb14c586316d5 | Define methods to listen events from backend | lib/adapter/wrapper.js | lib/adapter/wrapper.js | function DroongaProtocolConnectionWrapper(connection, callback, options) { // or (connection, options)
this._connection = connection;
if (typeof callback == 'function') {
this._callback = callback;
this._options = options;
} else {
this._callback = null;
this._options = callback;
}
}
DroongaProt... | JavaScript | 0.000002 | @@ -1026,32 +1026,495 @@
_options);%0A %7D,%0A
+ on: function(event, listener) %7B%0A this._connection.on(event, listener);%0A %7D,%0A once: function(event, listener) %7B%0A this._connection.once(event, listener);%0A %7D,%0A addListener: function(event, listener) %7B%0A this._connection.addListener(even... |
d0541b1bb7336a12b52c5a73ff5ceaa178da29a3 | use live innings, match innings doesn't always have remaining balls/overs | src/js/pebble-js-app.js | src/js/pebble-js-app.js | var matchid = "667715";
function update () {
var req = new XMLHttpRequest();
req.open('GET', "http://www.espncricinfo.com/ci/engine/match/"+matchid+".json");
req.onload = function(e) {
if (req.readyState == 4) {
if(req.status == 200) {
console.log("got new data, updating... | JavaScript | 0.000001 | @@ -3020,83 +3020,20 @@
ata.
+live.
innings
-.filter(function (innings) %7B return innings.live_current == 1; %7D)%5B0%5D
;%0A%0A
|
8b5d42b9fafffe776883496d43e34df7b17b4481 | Debug Alexa | lib/api/alexa/index.js | lib/api/alexa/index.js | 'use strict';
var moment = require('moment');
var _ = require('lodash');
function configure (app, wares, ctx, env) {
var entries = ctx.entries;
var express = require('express')
, api = express.Router( )
;
// invoke common middleware
api.use(wares.sendJSONStatus);
// text body typ... | JavaScript | 0.000001 | @@ -2808,32 +2808,55 @@
var
+direction;%0A
direction = 'Fla
|
22dbacf909035d8feacf4159031e518a9ca20d4e | update sauce labs custom launchers | test/sauce.conf.js | test/sauce.conf.js | const launchers = {}
const mobileLaunchers = [
['iOS', '8.4', 'Safari', 'iPhone 6 Simulator'],
['iOS', '9.3', 'Safari', 'iPhone 6s Simulator'],
['iOS', '10.3', 'Safari', 'iPhone 6s Simulator'],
['Android', '4.4', 'Browser', 'Android Emulator'],
['Android', '5.0', 'Browser', 'Android Emulator'],
['Android', '5.1'... | JavaScript | 0 | @@ -45,57 +45,8 @@
= %5B%0A
-%09%5B'iOS', '8.4', 'Safari', 'iPhone 6 Simulator'%5D,%0A
%09%5B'i
@@ -149,74 +149,73 @@
%0A%09%5B'
-Android', '4.4', 'Browser', 'Android Emulator'%5D,%0A%09%5B'Android', '5.0
+iOS', '11.1', 'Safari', 'iPhone 6s Simulator'%5D,%0A%09%5B'Android', '4.4
', '
@@ -753,11 +753,11 @@
'1.
-6.... |
625b884b17df60db5cfe4b24195efe191e13bf20 | Revert "refactor: use unprefixed matches function" | src/js/util/selector.js | src/js/util/selector.js | import {inBrowser} from './env';
import {removeAttr} from './attr';
import {isDocument, isElement, isString, startsWith, toNode, toNodes} from './lang';
export function query(selector, context) {
return toNode(selector) || find(selector, getContext(selector, context));
}
export function queryAll(selector, context... | JavaScript | 0 | @@ -101,16 +101,22 @@
sString,
+ noop,
startsW
@@ -2757,16 +2757,121 @@
pe : %7B%7D;
+%0Aconst matchesFn = elProto.matches %7C%7C elProto.webkitMatchesSelector %7C%7C elProto.msMatchesSelector %7C%7C noop;
%0A%0Aexport
@@ -2953,31 +2953,25 @@
ment =%3E
-elProto.
matches
+Fn
.call(el
|
b6a5b6435df331a4bddd03a9db7d63e66de546aa | fix hash function color selector | js/Helpers/SideSplit/MiniDraw.js | js/Helpers/SideSplit/MiniDraw.js | // need:
// ViewportCalibratedCanvas
// proxytools
// coordinateView (well, not really, but it'd be silly not to have)
// SideSplit
///////
// utils
function objToParamStr(obj) {
var parts = [];
for (var i in obj) {
if (obj.hasOwnProperty(i)) {
if (Array.isArray(obj[i])) {
//... | JavaScript | 0.000006 | @@ -1257,20 +1257,30 @@
lorlist%5B
+Math.abs(
hash
+)
%25 color
|
59294e8b0835fd190d289996df3d965c1c8968e4 | fix active-slide docs Closes #4210 | js/angular/directive/slideBox.js | js/angular/directive/slideBox.js |
/**
* @ngdoc directive
* @name ionSlideBox
* @module ionic
* @delegate ionic.service:$ionicSlideBoxDelegate
* @restrict E
* @description
* The Slide Box is a multi-page container where each page can be swiped or dragged between:
*
* 
var wrap = function (fn, before, after) {
return function () {
var args = Array.prototype.slice.call(arguments)
before.apply(this, args)
var result = fn.apply(this, args)
after.apply(this, args)
return result
}
}
var instrumentMethod = function (module, fn, t... | JavaScript | 0.000001 | @@ -3611,16 +3611,31 @@
ction, '
+app.controller.
scope')%0A
|
d39779a6d7fa26cfae0f7238b8b267a0beba4966 | Improve branch coverage. | test/store.test.js | test/store.test.js | import test from 'tape'
import { createStore } from '../src'
import { setRawStore } from '../src/store'
const data = {
a: 1,
b: {
c: new Date()
}
}
test('store.set(key, value)', t => {
t.plan(2)
const store = createStore()
store.set('key', 'value')
t.is(store.get('key'), 'value', 'Set & get string v... | JavaScript | 0 | @@ -645,33 +645,33 @@
t =%3E %7B%0A t.plan(
-2
+3
)%0A const store
@@ -875,24 +875,127 @@
in object.')
+%0A%0A t.throws(() =%3E %7B%0A store.set(function() %7B%7D)%0A %7D, 'Type of %60key%60 must be string or plain object.')
%0A%7D)%0A%0Atest('s
@@ -2406,16 +2406,18 @@
anged.b)
+ %7B
%0A t
@@ -2433,1... |
411336ae0518d8188adf887a43725959ceecbcc0 | Fix whitespace. | lib/check/resources.js | lib/check/resources.js | 'use strict';
var _ = require('lodash');
var Promise = require('bluebird');
const customResourceTypeRegex = /^Custom::.*/;
const requiredPropertyRegex = /Required: YesType/i;
// Creates an object (keyed by resource name) of properties that are required.
var getRequiredProperties = function (resources) {
return new ... | JavaScript | 0.99988 | @@ -3186,17 +3186,16 @@
-
validPro
@@ -3201,33 +3201,32 @@
opertiesErrors,%0A
-
|
7307c6ff40791146c39aababf3d44bb78ecae4bc | change pouchdb include | jxcore/app/app.js | jxcore/app/app.js | var BaseApp = require('rendr/shared/app')
, handlebarsHelpers = require('./lib/handlebarsHelpers');
var Backbone = require('backbone');
var BackbonePouch = require('backbone-pouch');
var PouchDB = require('backbone-pouch/node_modules/pouchdb');
//var PouchDB = require('../node_modules/backbone-pouch/node_modules/pouc... | JavaScript | 0 | @@ -174,24 +174,26 @@
ne-pouch');%0A
+//
var PouchDB
@@ -373,16 +373,18 @@
sync(%7B%0A
+//
db: new
|
0d906e4e0ead414022de093cc2700cb1eba4e6df | add warnings to Safari XML export | document/static/js/modules/editor/styles/index.js | document/static/js/modules/editor/styles/index.js | import {DocxExporter} from "../../exporter/docx"
import {OdtExporter} from "../../exporter/odt"
export class ModStyles {
constructor(editor) {
editor.mod.styles = this
this.editor = editor
this.exportTemplates = []
this.documentStyles = []
this.citationStyles = []
th... | JavaScript | 0 | @@ -88,16 +88,92 @@
ter/odt%22
+%0Aimport * as bowser from %22bowser/bowser%22%0Aimport %7BDialog%7D from %22../../common%22
%0A%0Aexport
@@ -898,24 +898,410 @@
%7D%0A %7D%0A%0A
+ showSafariErrorMessage() %7B%0A let dialog = new Dialog(%7B%0A title: gettext('Safari bug warning'),%0A ... |
102f7f0da22731cd93e01458a4ec791ef8eeae63 | Add standardize test. | test/test.stats.js | test/test.stats.js | describe("Stats", function () {
describe("round", function () {
it("the rounded value of 0.4281 is 0", function () {
var res;
res = stats.round(0.4281);
expect(res).to.equal(0);
});
it("the rounded value of 0.4281 with two decimal points is 0.43", functio... | JavaScript | 0.000001 | @@ -2237,32 +2237,316 @@
%7D);%0A %7D);%0A%0A
+ describe(%22standardize%22, function () %7B%0A it(%22the z score of %5B1,3,2%5D is %5B-1,1,0%5D%22, function () %7B%0A // Compare to MATLAB: zscore(%5B1,3,2%5D)%0A var res;%0A res = stats.standardize(%5B1, 3, 2%5D);%0A ... |
316f55f404c387fd778f294bf5761cf5c05ac009 | use `_name` instead of ctor name | lib/commands/config.js | lib/commands/config.js | 'use strict';
var path = require('path');
var normalize = require('../update');
var utils = require('../utils');
module.exports = function(app) {
return function(val, next) {
if (!utils.isObject(val)) {
console.error('config expects an object, cannot set "%s"', val);
process.exit(1);
}
var ... | JavaScript | 0.000059 | @@ -324,58 +324,14 @@
e =
-(
this.
-base && this.base.name) %7C%7C this.constructor.
+_
name
|
5626c9ff7afee63ab273fd29f4055e2f891bd637 | Add a test for config.data() | test/testConfig.js | test/testConfig.js |
/**
* Test for Configuration module
*/
var path = require('path');
var assert = require('assert');
var utils = require('./utils.js');
var config = require('../src/config.js');
describe('Config Module: ', function() {
beforeEach(function(done) {
// Clear situs global
delete process.env... | JavaScript | 0.000002 | @@ -3067,25 +3067,19 @@
alse if
-parameter
+key
is not
@@ -3291,17 +3291,224 @@
if
-parameter
+key exist', function() %7B%0A%0A process.env.SITUS = JSON.stringify(%7Bsource: './situs'%7D);%0A assert.equal('./situs', config.data('source'));%0A%0A %7D);%0A%0A it('should set new... |
b388ae46f7025b37cd9018a259b591c326d8c49a | Add missing export | src/api/typingtest.js | src/api/typingtest.js | import { db } from '../main';
import { addCompetition, getRunningCompetitions } from '../competition-store';
// Creates a new typing test.
// If the typing test is for a competition, create a competition
// in the competition store as well.
export function createTypingTest(req, res) {
const { language, finished, co... | JavaScript | 0.00006 | @@ -1297,24 +1297,31 @@
tabase?%0A%7D%0A%0A%0A
+export
function get
|
9e71e736e372c56e0504e0b4554e53ea8f5e1506 | enhance tests to check getHistory | test/testSQLite.js | test/testSQLite.js | var expect = require('chai').expect;
var setup = require(__dirname + '/lib/setup');
var objects = null;
var states = null;
var onStateChanged = null;
var onObjectChanged = null;
var sendToID = 1;
var adapterShortName = setup.adapterName.substring(setup.adapterName.indexOf('.')+1);
function checkConnectionOfAdapter... | JavaScript | 0 | @@ -5745,24 +5745,1123 @@
e.equal(3);%0A
+%0A sendTo('sql.0', 'getHistory', %7B%0A id: 'system.adapter.history.0.memRss',%0A options: %7B%0A end: ... |
3e2c62e5b2ae0ca26a6862cf142d3d1223e3ae86 | Check for path when creating new project | lib/commands/create.js | lib/commands/create.js | import fs from 'fs';
import path from 'path';
import {execSync} from 'child_process';
import {createDir, getFileContent, createFile, getLineBreak} from '../utils';
import {logger} from '../logger';
import shelljs from 'shelljs/shell';
export default function create(appPath) {
const lineBreak = getLineBreak();
let ... | JavaScript | 0 | @@ -271,16 +271,151 @@
Path) %7B%0A
+ if (typeof appPath === 'undefined' %7C%7C appPath === '') %7B%0A console.log('Error: Please supply the path of project');%0A return;%0A %7D%0A
const
|
8490b2a17816dbb646796e268096bff4233a5efb | Please fix things | js/saiku/plugins/Chart/plugin.js | js/saiku/plugins/Chart/plugin.js | var Chart = Backbone.View.extend({
initialize: function(args) {
this.workspace = args.workspace;
// Create a unique ID for use as the CSS selector
this.id = _.uniqueId("chart_");
$(this.el).attr({ id: this.id });
// Bind table rendering to query result event... | JavaScript | 1 | @@ -1101,17 +1101,16 @@
%22url('
-/
js/saiku
|
da4e1d9e0e4949dd360ebcb5b454943584c7d5aa | fix update command when install folder already exists | lib/commands/update.js | lib/commands/update.js | 'use strict';
const fs = require('fs-extra');
const path = require('path');
const Listr = require('listr');
const symlinkSync = require('symlink-or-copy').sync;
// Utils
const errors = require('../errors');
const Config = require('../utils/config');
const resolveVersion = require('../utils/resolve-version');
const che... | JavaScript | 0 | @@ -2643,24 +2643,279 @@
task) =%3E %7B%0A
+ if (fs.existsSync(ctx.installPath)) %7B%0A if (!ctx.force) %7B%0A task.skip('Version already installed.');%0A return;%0A %7D%0A%0A fs.removeSync(ctx.installPath);%0A %7... |
c5d44a860e4117d9376afad8998500a2ecf8d0b5 | Add formComponents in Form | lib/components/form.js | lib/components/form.js | import React from 'react'
import request from 'axios'
import { useSheet } from '../jss'
import { endpoints } from '../config'
const styles = {
}
const Form = React.createClass({
getInitialState() {
return {
account: '',
repository: '',
data: {
title: '---',
fields: []
}
... | JavaScript | 0.000001 | @@ -120,16 +120,178 @@
onfig'%0A%0A
+import InputText from './input-text'%0Aimport InputCheckboxes from './input-checkboxes'%0Aimport InputRadios from './input-radios'%0Aimport Textarea from './textarea'%0A%0A
const st
@@ -911,28 +911,584 @@
-return (%0A %3Cdl%3E%0A
+if (!this.state.data.fields.length) %7B... |
95a297cbd7ce521f837651276aeb5e2dc0d88c60 | remove pot.platform.museum | gulpy/ext/platform.js | gulpy/ext/platform.js |
/*
* Расширение platform для пота
*/
var _ = require('lodash');
module.exports = function(pot) {
var names = ['phone', 'tablet', 'ie8', 'ie9', 'museum'];
var platform = {};
names.map(function(name) {
if (pot.args[name]) {
platform[name] = true;
}
});
var touch = po... | JavaScript | 0.00215 | @@ -147,18 +147,8 @@
ie9'
-, 'museum'
%5D;%0A
@@ -735,8 +735,9 @@
form;%0A%7D;
+%0A
|
c4491b11b08b5ab51651403c445cb88f47de7692 | modify stylelint config | dotfiles/xdg_config/stylelint/stylelint.config.js | dotfiles/xdg_config/stylelint/stylelint.config.js | const path = require('path')
module.exports = {
extends: path.join(
process.env.NPM_CONFIG_PREFIX,
'lib', 'node_modules', 'stylelint-config-standard'
),
rules: {
'at-rule-empty-line-before': ['always', { except: ['all-nested'] }],
},
}
| JavaScript | 0.000001 | @@ -236,16 +236,35 @@
-nested'
+, 'blockless-group'
%5D %7D%5D,%0A
|
e31c720df3e5340f28fe1c59862f0e32427028c8 | Call HandleNotShiftYetTable. | src/assets/compute.js | src/assets/compute.js | /* eslint-disable */
/**
* Created by max on 2017/1/20.
*/
var FindAttrList = require('./findAttrList');
var HandlePeopleInfo = require('./handlePeopleInfo');
var HandleNotShiftYetTable = require('./handleNotShiftYetTable');
var peopleCountInShift = 0; //每班需要幾人
const LINES_NUMBER_FROM = 1;
var shifting = function (... | JavaScript | 0 | @@ -1450,24 +1450,27 @@
axNumber);%0A
+ //
let notShif
|
d0abe7144cce1576b6fef8d921c955640f517a5d | fix aliasing | src/assets/fractal.js | src/assets/fractal.js | (function() {
// Cache variables
var modules = {}, // cache of modules
scriptTags = [],
references = {}, // cache of reference maps
EXTENSIONS = ['js'];
/**
* Load script from the path and bind callback on onload event passing
* result of async require of given module... | JavaScript | 0.000017 | @@ -4902,20 +4902,88 @@
-var filename
+// look for aliased version%0A if (!modules%5Brequest%5D) %7B%0A request
= r
@@ -5013,22 +5013,32 @@
e__)
-,
+;
%0A
+ %7D%0A
+ var
modu
@@ -5050,24 +5050,23 @@
modules%5B
-filename
+request
%5D;%0A
@@ -5181,24 +5181,23 @@
modul... |
c3b5ed5b3d401bcce80bbe0cdd219d0c3974e7b5 | Fix grammatical issue | src/babel/messages.js | src/babel/messages.js | import * as util from "util";
export const MESSAGES = {
tailCallReassignmentDeopt: "Function reference has been reassigned, so it will probably be dereferenced, therefore we can't optimise this with confidence",
JSXNamespacedTags: "Namespace tags are not supported. ReactJSX is not XML.",
classesIllegalBareSuper... | JavaScript | 0.000102 | @@ -1393,16 +1393,17 @@
his node
+'
s positi
|
0d55a0eecd127220dd9535be4ba9bdeae7ddf4e7 | allow custom column attributes | knockout-table.js | knockout-table.js | ;(function(factory) {
if (typeof require === 'function' && typeof exports === 'object' && typeof module === 'object') {
// CommonJS
factory(require('knockout'), require('jquery'));
} else if (typeof define === 'function' && define.amd) {
// AMD
define(['knockout', 'jquery'], fact... | JavaScript | 0.000001 | @@ -3233,33 +3233,30 @@
-this.label =
+$.extend(this,
config
-.label
+)
;%0A
@@ -3270,28 +3270,21 @@
his.
-field = config.field
+table = table
;%0A
@@ -3305,22 +3305,20 @@
plate =
-config
+this
.templat
@@ -3378,22 +3378,20 @@
lueFn =
-config
+this
.valueFn
|
f75cf3d865ed0d9e688bf7274c8a9cd615d8719c | Increment core's version | builtins/core.other.js | builtins/core.other.js | const {Command, Feature, StagedMessageResult} = require('other')
const feature = new Feature({
name: 'Core',
version: '0.0.1',
dependencies: {
otherjs: '1.1.x'
}
})
feature.commands.push(new Command({
tokens: ['/blockquote', '/caption', '/h1', '/h2', '/h3', '/p', '/s'],
onQuery(token, query) {
ret... | JavaScript | 0 | @@ -121,17 +121,17 @@
n: '0.0.
-1
+2
',%0A dep
|
094847c5dfd1d2d923bad92faa328a9e8ae3165c | Update scripts.js | mods/gen6/scripts.js | mods/gen6/scripts.js | exports.BattleScripts = {
init: function() {
for (var i in this.data.FormatsData)
this.data.FormatsData[i].dreamWorldRelease = true;
}
this.data.Pokedex.azumarill.types = ["Water","Fairy"];
this.data.Learnsets.azumarill.learnset.lunardance = ['5L0'];
this.data.Learnsets... | JavaScript | 0.000002 | @@ -19,16 +19,20 @@
pts = %7B%0A
+
init
@@ -46,16 +46,24 @@
ion() %7B%0A
+
@@ -103,32 +103,44 @@
ta)%0A
+
+
this.data.Format
@@ -178,15 +178,8 @@
ue;%0A
- %09%7D%0A
|
698cb7833b68c413bd2e615d4f99bfd88cba4122 | organize indent | public/js/app.js | public/js/app.js | "use strict";
define([
'angular',
'angular-inbox',
'angularRoute',
'angularSanitize',
'angularCookies',
'angularAnimate',
'angularStrap',
'angularInfiniteScroll',
'baobab.controller.app',
'baobab.controller.threadList',
'baobab.controller.thread',
'baobab.controller.compose',
'baobab.service.... | JavaScript | 0.999057 | @@ -3124,20 +3124,16 @@
-
var c =
@@ -3139,20 +3139,16 @@
ca%5Bi%5D;%0A
-
@@ -3200,20 +3200,16 @@
-
if (c.in
@@ -3234,20 +3234,16 @@
!= -1)%0A
-
@@ -3335,16 +3335,18 @@
false)%0A
+
wind
|
6dbc6dd5eada867f560d29d1236d96b63658b919 | Format comments | src/languages/groovy.js | src/languages/groovy.js | /*
Language: Groovy
Author: Guillaume Laforge <glaforge@gmail.com>
Website: http://glaforge.appspot.com
Description: Groovy programming language implementation inspired from Vsevolod's Java mode
*/
function(hljs) {
return {
keywords: {
typename: 'byte short char int long boolean float doub... | JavaScript | 0 | @@ -397,20 +397,16 @@
-
// groov
@@ -461,28 +461,24 @@
t trait ' +%0A
-
|
fe2928d0607cee3864b0746852c27bc502b996f6 | Fix receiveGetExistingTag in PropertySelect test. | assets/js/modules/analytics/common/property-select.test.js | assets/js/modules/analytics/common/property-select.test.js | /**
* Property Select component tests.
*
* Site Kit by Google, Copyright 2020 Google LLC
*
* 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
*
* https://www.apache.org/licenses/LICEN... | JavaScript | 0 | @@ -1909,16 +1909,27 @@
nsAccess
+.propertyID
);%0A%09//
|
da3027cd957f6a035307447d82cdb07d60086be4 | Update assets/js/modules/tagmanager/hooks/useExistingTagEffect.js. | assets/js/modules/tagmanager/hooks/useExistingTagEffect.js | assets/js/modules/tagmanager/hooks/useExistingTagEffect.js | /**
* Tag Manager useExistingTag custom hook.
*
* Site Kit by Google, Copyright 2021 Google LLC
*
* 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
*
* https://www.apache.org/license... | JavaScript | 0 | @@ -1712,17 +1712,17 @@
)();%0A%09%7D,
-%09
+
%5B%0A%09%09hasE
@@ -1843,14 +1843,14 @@
ByID,%0A%09%5D
-%09
+
);%0A%7D%0A
|
1eb7e5e49b6a8881e7e2d0ad8243ff92a840497d | Revert Element checking | app/assets/javascripts/components/Elements.js | app/assets/javascripts/components/Elements.js | import React, {Component} from 'react';
import {DragDropContext} from 'react-dnd';
import {Col} from 'react-bootstrap';
import HTML5Backend from 'react-dnd-html5-backend';
import _ from 'lodash';
import List from './List';
import ElementDetails from './ElementDetails';
import ElementStore from './stores/ElementStore';... | JavaScript | 0 | @@ -745,114 +745,8 @@
te;%0A
- const isNewElement = !_.isEqual(currentElement, this.state.currentElement);%0A if (isNewElement) %7B%0A
@@ -780,22 +780,16 @@
ent %7D);%0A
- %7D%0A
%7D%0A%0A r
|
34fb27c8dd1d0fb4203d8199bd267eff5773cc76 | Add support for CC's COMMIT_ID env var | src/lib/assets/index.js | src/lib/assets/index.js | const fs = require('fs');
const childProcess = require('child_process');
let version = require('../../../package.json').version;
try {
version = childProcess.execSync('git log -1 "--format=%H"', { encoding: 'utf8' }).trim();
} catch (e) {
try {
version = fs.readFileSync(__dirname + '/../../../sha.txt', 'utf8').tri... | JavaScript | 0 | @@ -361,16 +361,41 @@
ersion =
+ process.env.COMMIT_ID %7C%7C
version
|
e8d4c98a1b78fbb2e4347e2cf6d3cdbf896d24b3 | fix create#games | app/assets/javascripts/games/games.factory.js | app/assets/javascripts/games/games.factory.js | (function() {
'use strict';
function GamesFactory($http) {
return {
getGames: getGames,
getPublishers: getPublishers,
getGenres: getGenres,
getPlatforms: getPlatforms,
getGoodfors: getGoodfors,
getGame: getGame,
createGame: createGame,
updateGame: updateGame,
... | JavaScript | 0.000001 | @@ -53,16 +53,27 @@
ry($http
+, $location
) %7B%0A%0A
@@ -1389,16 +1389,115 @@
tp(req)%0A
+ .then(function(response) %7B%0A $location.path('/games')%0A %7D)%0A
@@ -1593,22 +1593,16 @@
ame() %7B%0A
-
%0A %7D%0A%0A
@@ -1822,14 +1822,11 @@
ry)%0A
-
... |
44072421df3dc0e628ad8c0b37867be8095e4660 | corrige pequeno erro no texto da função favorável | pontocerto/static/js/pontocerto.js | pontocerto/static/js/pontocerto.js | /* Project specific Javascript goes here. */
var data, geojson;
var map = L.map('map').setView([-12.9696, -38.4676], 13);
var mapTiles = L.tileLayer('http://a.tile.thunderforest.com/transport/{z}/{x}/{y}.png', {
attribution: 'Maps © <a href="http://www.thunderforest.com">Thunderforest</a>, \
Data... | JavaScript | 0.000169 | @@ -1825,22 +1825,22 @@
oravel%22%3E
-f
+F
avor
-a
+%C3%A1
vel%3C/spa
|
875fde2470c2e154b3d01b545acaf502f2b8957a | Remove old Google Analytics Module | app/assets/javascripts/modules/moj.AsyncGA.js | app/assets/javascripts/modules/moj.AsyncGA.js | /*global ga */
(function() {
'use strict';
moj.Modules.AsyncGA = {
el: '.js-AsyncGA',
init: function() {
GOVUK.Analytics.load();
if($(this.el).length>0){
this.render();
}
},
render: function() {
// Use document.domain in dev, preview and staging so that tracking wor... | JavaScript | 0 | @@ -121,40 +121,11 @@
-GOVUK.Analytics.load();%0A
if
+
($(t
@@ -142,11 +142,14 @@
ngth
-%3E
+ %3E
0)
+
%7B%0A
@@ -391,18 +391,25 @@
Domain =
+%0A
-(
document
@@ -432,17 +432,16 @@
.gov.uk'
-)
? '.www
@@ -539,160 +539,506 @@
-// Configure profiles and make interface public%0A ... |
452e74833058b568f0934e78a5a67cb5e4c55303 | Correct code tranform | app/assets/javascripts/rocketchat_observer.js | app/assets/javascripts/rocketchat_observer.js | "use strict";
var rocketChatIframe = {
rcAvailableInIframe: false,
iframeLoad: false,
url: ''
};
var handler = function () {
return {
set: function (target, key, value) {
target[key] = value;
if (target.rcAvailableInIframe && target.iframeLoad && window.iframeEl.src.length !== target.url.length) {
conso... | JavaScript | 0.000607 | @@ -1,18 +1,4 @@
-%22use strict%22;%0A
var
@@ -17,18 +17,17 @@
rame = %7B
-%0A%09
+
rcAvaila
@@ -45,18 +45,17 @@
: false,
-%0A%09
+
iframeLo
@@ -68,18 +68,17 @@
lse,
-%0A%09
+
url: ''
-%0A
+
%7D;%0Av
@@ -291,33 +291,8 @@
) %7B%0A
-%09%09%09%09console.log(target);%0A
%09%09%09%09
@@ -329,16 +329,37 @@
rl... |
84eb82c7f70ca8347d98af35bc8604badc636d94 | Add proptypes | app/components/mastorownotificationsfollow.js | app/components/mastorownotificationsfollow.js | import React, { Component } from "react";
import { View, Text, StyleSheet, Image, Linking } from "react-native";
import { FontAwesome } from "@expo/vector-icons";
export default class MastoRowNotificationfollow extends Component {
constructor(props) {
super(props);
this.props = {
id:pro... | JavaScript | 0.000002 | @@ -155,16 +155,52 @@
-icons%22;
+%0Aimport PropTypes from %22prop-types%22;
%0A%0Aexport
@@ -269,68 +269,23 @@
-constructor(props) %7B%0A super(props);%0A this.prop
+static propType
s =
@@ -298,29 +298,30 @@
-
id:
-props.id,%0A
+ PropTypes.string,%0A
@@ -333,24 +333,27 @@
... |
4147cc71073f6a1aa4b44935957007421472d8c3 | Fix hint in exercise demo | app/js/arethusa.exercise/fill_in_the_blank.js | app/js/arethusa.exercise/fill_in_the_blank.js | 'use strict';
angular.module('arethusa.exercise').service('fillInTheBlank', [
'configurator',
'morph',
'state',
function (configurator, morph, state) {
var self = this;
function configure() {
configurator.getConfAndDelegate('fillInTheBlank', self);
self.started = false;
self.answers = ... | JavaScript | 0.000001 | @@ -665,33 +665,8 @@
emma
- + ', ' + morph.num + '.'
,%0A
|
9db788e560bcac03bd5ae41886ccc192ac13dbdf | Revert "remove alias for host in watch command" | src/commands/watch.js | src/commands/watch.js | import asyncCommand from '../lib/async-command';
import getSslCert from '../lib/ssl-cert';
import runWebpack, { showStats } from '../lib/webpack/run-webpack';
export default asyncCommand({
command: 'watch [src]',
desc: 'Start a development live-reload server.',
builder: {
src: {
description: 'Entry file (ind... | JavaScript | 0 | @@ -519,16 +519,31 @@
0.0.0.0'
+,%0A%09%09%09alias: 'h'
%0A%09%09%7D,%0A%09%09
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.