messages
listlengths
2
2
language
stringclasses
8 values
prompt_type
stringclasses
2 values
lint_errors
int64
0
129
⌀
cyclomatic_complexity
int64
0
32
⌀
license
stringclasses
7 values
commit
stringlengths
40
40
repos
stringlengths
5
116k
new_file
stringlengths
4
220
status
stringclasses
6 values
error
stringlengths
26
74
⌀
is_valid_syntax
bool
2 classes
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nvar assign = require('object-assign');\nvar debug = require('debug')('duosass');\nvar sass = require('node-sass').renderSync;\n\n/**\n * Compile Sass to CSS\n *\n * @param {Object} [opts]\n * @api public\n * @return {Fu...
javascript
edit
0
4
mit
e09ea80c6ad9b4d10bf96879db575d617b08c41d
duojs/sass
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n\"use strict\";\n\n/**\n * pretty json middleware.\n *\n * - `always`: prettify response without query, if it's specified true. (default: false)\n * - `query`: query-string parameter name for pretty response. (default: none)\n * - `s...
javascript
edit
0
4
mit
7e7f0ecae0cf13dd19093e96ff292c7ce915dd6c
stoshiya/express-prettify
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nconst fs = require(\"fs\");\n\nif (fs.existsSync('./build/Release/cppmap.node')) {\n module.exports = require('./build/Release/cppmap').WeakValueMap;\n} else if (fs.existsSync('./build/Debug/cppmap.node')) {\n con...
javascript
edit
0
0
mit
cfa9cd5e6208ee22483f8d93563c715e9bca8ad4
amapili/weak-value-map,amapili/weak-value-map,amapili/weak-value-map
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nconst { client } = require('nightwatch-cucumber')\nconst { defineSupportCode } = require('cucumber')\nconst { set, get, assign } = require('lodash')\n\ndefineSupportCode(({ Given, When }) => {\n const Company = client.page.Company()\n\...
javascript
edit
0
1
mit
6a1bc0d4cd6d1b46e0e32b310025ef196bfb7940
uktrade/data-hub-fe-beta2,uktrade/data-hub-frontend,uktrade/data-hub-frontend,uktrade/data-hub-fe-beta2,uktrade/data-hub-frontend
test/acceptance/features/companies/step_definitions/save.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n// Copyright (c) 2018, Frappe Technologies and contributors\n// For license information, please see license.txt\n\nfrappe.ui.form.on('Energy Point Rule', {\n\trefresh: function(frm) {\n\t\tfrm.events.set_user_and_multiplier_field_option...
javascript
edit
0
3
mit
9d96d707af8f090709b59b6a0cf064fbd1ecc96b
adityahase/frappe,vjFaLk/frappe,vjFaLk/frappe,saurabh6790/frappe,StrellaGroup/frappe,almeidapaulopt/frappe,vjFaLk/frappe,mhbu50/frappe,StrellaGroup/frappe,adityahase/frappe,saurabh6790/frappe,almeidapaulopt/frappe,mhbu50/frappe,frappe/frappe,yashodhank/frappe,yashodhank/frappe,saurabh6790/frappe,StrellaGroup/frappe,yas...
frappe/social/doctype/energy_point_rule/energy_point_rule.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar path = require('path');\nvar fs = require('fs');\nvar isUrl = require('is-url');\n\nvar notFound = function (settings, store) {\n return function (req, res, next) {\n res.statusCode = 404;\n res.send(getErrorPage(req.config, ...
javascript
edit
0
4
mit
03fca8e40f1292d231d8620a641a4b2786011293
cysys/stratum,divshot/superstatic,carrot/superstatic,divshot/superstatic,firebase/superstatic,firebase/superstatic,cysys/stratum,nnnnathann/superstatic,aj0strow/superstatic,aj0strow/superstatic,firebase/superstatic
lib/server/middleware/not_found.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n\nmodule.exports = {\n\tdomain_name: \"kekeke.com\",\n\tbind_port: 8000,\n\twork_dir: './work_dir',\n\tdst_dir: './dst_dir',\n\tfork_num: 8,\n\tidle_time: 5 * 60 * 1000,\n\tbuffer_size: 64 * 1024,\n\tmail_data_max: 10 * 1024 * 1024,\n\t...
javascript
edit
0
0
apache-2.0
079964574d4167447fb5d3d1d65c2cda5df101cf
tedyu002/smtp_nodejs
config.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\nvar Memcached = require('memcached'),\n replify = require('replify'),\n Promise = require('rsvp').Promise;\n\n\nmodule.exports = function(connection) {\n\n var memcachedstore = new Memcached(connection);\n\n var A...
javascript
edit
0
3
mit
8d7aa137630d7241f95ebd53a78a7be0fe80c8ef
pandoraui/jsbin,pandoraui/jsbin,jwdallas/jsbin,knpwrs/jsbin,fgrillo21/NPA-Exam,dhval/jsbin,simonThiele/jsbin,IvanSanchez/jsbin,peterblazejewicz/jsbin,jamez14/jsbin,roman01la/jsbin,roman01la/jsbin,dennishu001/jsbin,svacha/jsbin,fend-classroom/jsbin,knpwrs/jsbin,eggheadio/jsbin,KenPowers/jsbin,dhval/jsbin,dedalik/jsbin,K...
lib/addons/memcached/store.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n// Whether given error is an error thrown by require internals in case module\n// (at given path) was not found\n\n\"use strict\";\n\nvar pathToken = \":path\", pattern;\n\ntry { require(pathToken); }\ncatch (e) { pattern = e.message; }...
javascript
edit
0
2
isc
c9b9cc8ba9a24335bb90ec7f147507f40081fd8c
medikoo/cjs-module
is-module-not-found-error/index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nAT.prototype.atOauthHelpers = {\n oauthService: function() {\n return AccountsTemplates.oauthServices();\n },\n};\n```\n\nApply this change: Convert indentation to 2 spaces" }, { "role": "assistant", "content": ...
javascript
edit
0
1
mit
092d76f10b79288cd17d9de75330e5967882284e
evgenTraytyak/core,evgenTraytyak/core
lib/templates_helpers/at_oauth.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar express = require('express');\nvar cardsets = require('./libs/cardsets');\nvar path = require('path');\n\nvar app = express();\nvar httpServer = app.listen(process.env.PORT || 8080);\n\n\napp.use('/sets', cardsets);\napp.use(express...
javascript
edit
0
0
mit
96cda5f45ae374d3f72e3e26453829d756c2a64a
angel333/vogame
app.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nlet del = require('del');\n\ndel(['public/**']).then(function () {\n console.log('/public dir is deleted');\n});\n\n```\n\nApply this change: Make it run on Node 4\n\n[ci skip]" }, { "role": "assistant", "content": "var d...
javascript
edit
0
1
apache-2.0
482ff9b2513bf9df2e5a4394fea469a4ef69f6c6
spolnik/JAlgoArena-UI,spolnik/JAlgoArena-UI,spolnik/JAlgoArena-UI
deletePublicDir.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n\"use strict\";\n// DO NOT EDIT THIS FILE, EDIT THE GRUNT TASK NGCONSTANT SETTINGS INSTEAD WHICH GENERATES THIS FILE\nangular.module('publisherApp')\n\n.constant('ENV', 'dev')\n\n.constant('VERSION', '1.1.1-SNAPSHOT')\n\n;\n```\n\nApply...
javascript
edit
0
0
apache-2.0
dd8e9e43399648722d60d9fd9bf43906a9da6015
EsupPortail/esup-publisher,GIP-RECIA/esup-publisher-ui,EsupPortail/esup-publisher,GIP-RECIA/esup-publisher-ui,EsupPortail/esup-publisher,GIP-RECIA/esup-publisher-ui,EsupPortail/esup-publisher
src/main/webapp/scripts/app/app.constants.js
rejected_duplicate
Near-duplicate of sample 70904
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/** @babel */\n\nimport {spawnSync} from 'child_process'\n\nconst ENVIRONMENT_VARIABLES_TO_PRESERVE = new Set(['NODE_ENV', 'NODE_PATH'])\n\nexport default function updateProcessEnv (launchEnv) {\n let envToAssign\n if (launchEnv.PWD) ...
javascript
edit
0
9
mit
c0e94aac5e0aef19ca31abf029ff68531614152c
Mokolea/atom,atom/atom,xream/atom,kevinrenaers/atom,FIT-CSE2410-A-Bombs/atom,brettle/atom,brettle/atom,brumm/atom,decaffeinate-examples/atom,liuderchi/atom,sotayamashita/atom,liuderchi/atom,AlexxNica/atom,CraZySacX/atom,Mokolea/atom,stinsonga/atom,Arcanemagus/atom,bolinfest/atom,tjkr/atom,decaffeinate-examples/atom,bre...
src/update-process-env.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/*!\n * jQuery UI Effects Transfer @VERSION\n * http://jqueryui.com\n *\n * Copyright jQuery Foundation and other contributors\n * Released under the MIT license.\n * http://jquery.org/license\n */\n\n//>>label: Transfer Effect\n//>>gro...
javascript
edit
0
3
mit
9f6d924515be0d162c8fa726e9e73f600311ec09
GrayYoung/jQuery.UI.Extension,GrayYoung/jQuery.UI.Extension
ui/effects/effect-transfer.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/*!\n * TemplateLayout Wef plugin\n * Copyright (c) 2011 Pablo Escalada\n * MIT Licensed\n */\n\n//requires: cssParser\nvar parser = wef.fn.cssParser; //TODO: loader\n//exports: templateLayout\n\n\n\n(function () {\n var templateLayo...
javascript
edit
0
1
mit
01ec164a3f5b0ba419242f39e674c69dbdfea153
diesire/wef,diesire/wef,diesire/wef
plugins/templateLayout/src/templateLayout.wef.js
rejected_duplicate
Near-duplicate of sample 90510
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport Trie from 'triejs';\nimport { forEach, addIndex, toLower } from 'ramda';\n\nconst forEachIndex = addIndex(forEach);\n\n/**\n * Remove trailing newlines\n */\nexport const normalize = (rawText) =>\n rawText.replace(/(.)(\\r\\n|\\...
javascript
edit
0
1
mit
f14a542b5d0fdb8dc96a5a944dc65abe2321bdd8
UpBeet/tree-of-scheherazade,UpBeet/tree-of-scheherazade
src/parser/parser.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar Namespace = (function (global) {\n\n 'use strict';\n\n return {\n\n /**\n * Creates a global object in a single line.\n * // example\n * Namespace.create('foo.bar'); // -> foo.bar\n *\n * @param {string} nam...
javascript
edit
0
3
mit
e87c0a58d4ad98fc02bcd2bdcbf6eb31a9a93af2
cange/namespace-js,cange/namespace-js
namespace.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/**\n * Copyright (c) Ajay Sreedhar. All rights reserved.\n *\n * Licensed under the MIT License.\n * Please see LICENSE file located in the project root for more information.\n */\n\n/**\n * @typedef {Object} App_ServiceModel - The ser...
javascript
edit
0
0
mit
3a744092e9936d44b6d137cb1153f4ac8a943bcd
ajaysreedhar/kongdash,ajaysreedhar/kongdash,ajaysreedhar/kongdash
src/models/service-model.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nconst path = require('path');\r\nconst webpack = require('webpack');\r\nconst HardSourceWebpackPlugin = require('hard-source-webpack-plugin');\r\n\r\nmodule.exports = {\r\n context: path.resolve(__dirname, './src'),\r\n entry: {\r...
javascript
edit
0
0
apache-2.0
69cca8f1ba5300e7083994048b66dda9b7411c01
NicolasBuecher/Babylon.js,BabylonJS/Babylon.js,sebavan/Babylon.js,jbousquie/Babylon.js,BabylonJS/Babylon.js,sebavan/Babylon.js,NicolasBuecher/Babylon.js,BabylonJS/Babylon.js,Kesshi/Babylon.js,Kesshi/Babylon.js,NicolasBuecher/Babylon.js,jbousquie/Babylon.js,RaananW/Babylon.js,jbousquie/Babylon.js,RaananW/Babylon.js,seba...
materialsLibrary/webpack.config.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport React from 'react';\nimport { Route, IndexRoute, Redirect } from 'react-router';\n\nimport App from './components/App';\nimport FriendListApp from './containers/FriendListApp/FriendListApp';\nimport MonsterFinderApp from './conta...
javascript
edit
0
0
mit
056e49d733e8646ccd6198a513eec04151a7c625
mileszs/dwtools,mileszs/dwtools
src/js/routes.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/**\n * Composes single-argument functions from right to left.\n *\n * @param {...Function} funcs The functions to compose.\n * @returns {Function} A function obtained by composing functions from right to\n * left. For example, compose(...
javascript
edit
0
2
mit
8eb0532c0599dd36a58114072efecbda3ec65c1b
neighborhood999/redux,neighborhood999/redux,paulkogel/redux,chentsulin/redux,joshwreford/idle-game,Aweary/redux,tatsuhino/reactPractice,tatsuhino/reactPractice,keyanzhang/redux,CompuIves/redux,leoasis/redux,joshwreford/idle-game,mikekidder/redux,javascriptjedi/redux-select,mjw56/redux,jas-chen/redux,gaearon/redux,Awear...
src/utils/compose.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n(function (exports) {\n 'use strict';\n\n function BrowserMusicPlayer () {\n var AudioContext = window.AudioContext || window.webkitAudioContext;\n this.ctx = new AudioContext();\n }\n\n BrowserMusicPlayer.prot...
javascript
edit
0
2
mit
bd29912e3dab545589e940a34e0766618ea8dcf0
kubosho/simple-music-player
app/scripts/browser-music-player.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport React from 'react';\nimport { map } from 'lodash';\n\nconst MetaInformation = (props) => (\n <div className=\"container\">\n {props.title ? <h4 className=\"heading\">{props.title}</h4> : null}\n {\n map(props.details,...
javascript
edit
0
2
mit
2bd35e9aaa12e1c7780d80114d48b53a143a083d
DoSomething/rogue,DoSomething/rogue,DoSomething/rogue
resources/assets/components/MetaInformation/index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nexport const BASE = 'https://online.ntnu.no/';\nexport const API_BASE = `${BASE}api/v1/`;\nexport const API_AUTH = 'auth/';\nexport const API_USERS = 'usersaldo/';\nexport const API_INVENTORY = 'inventory/';\nexport const API_RFID = 'rf...
javascript
edit
0
0
mit
7266168d703875b8d83d14a511cca73c68b7775c
dotkom/Nibble2,dotkom/Nibble2,dotkom/Nibble2
app/src/common/constants.example.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n// Only create a server if we are in an environment with a HTTP server\n// (as opposed to, eg, a command-line tool).\n//\nif (Package.webapp) {\n if (process.env.DDP_DEFAULT_CONNECTION_URL) {\n __meteor_runtime_config__.DDP_DEFAULT_...
javascript
edit
0
1
mit
eeb95efaedfcbf2f7d5bb1d9bad984e470ed32e8
jagi/meteor,luohuazju/meteor,newswim/meteor,dandv/meteor,ljack/meteor,yonglehou/meteor,fashionsun/meteor,mjmasn/meteor,tdamsma/meteor,chengxiaole/meteor,Hansoft/meteor,joannekoong/meteor,lieuwex/meteor,baiyunping333/meteor,jdivy/meteor,qscripter/meteor,fashionsun/meteor,mubassirhayat/meteor,alphanso/meteor,youprofit/me...
packages/ddp/server_convenience.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar path = require('path');\nvar fs = require('fs');\n\nvar mimetypes = {\n '.gif': 'image/gif',\n '.jpeg': 'image/jpeg',\n '.jpg': 'image/jpeg',\n '.jpe': 'image/jpeg',\n '.png': 'image/png',\n '.bmp': 'image/bmp'\n};\n\nv...
javascript
edit
0
7
mit
55574c742dfe6ee23805e575371ad91c668a1664
gtb104/mct-convert-image-to-base64
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar Transpiler = require('./transpiler');\n\nmodule.exports = {\n\tname: 'ember-cli-6to5',\n\tincluded: function(app) {\n\t\tthis._super.included.apply(this, arguments);\n\n\t\tvar options = getOptions(app.options['6to5']);\n\t\tvar plu...
javascript
edit
0
6
mit
e20b7d7d070a47486b2636f423b66f16ae0e4d2f
sebmck/ember-cli-babel,RyannosaurusRex/ember-cli-typescript,babel/ember-cli-babel,pangratz/ember-cli-babel,SlexAxton/ember-cli-babel,kittens/ember-cli-babel,babel/ember-cli-babel,sebmck/ember-cli-babel,SlexAxton/ember-cli-babel,djchie/ember-cli-babel,RyannosaurusRex/ember-cli-typescript,pangratz/ember-cli-babel,djchie/...
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar basicAuth = require('basic-auth');\n\nvar unauthorized = function(res, realm) {\n var realm = realm || 'Authorization Required';\n res.set('WWW-Authenticate', 'Basic realm=' + realm);\n\n return res.sendStatus(401);\n};\n\nmodule...
javascript
edit
0
9
mit
e40654ebf8690d663ef23ed60c5c353af8a0bc68
nchaulet/basicauth-middleware
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar ids = ['yeka52', 'maboyong', 'datouma', 'gaizhilizcw', 'tianhao', 'qinnan', 'lianghuan', 'talich', \n'loveletter', 'zenithdie', 'Glasschurch', 'nosensedigit', 'oldplusnew', 'negative2', \n'taosay', 'DKLearnsPop', 'mactalk', 'lswlsw'...
javascript
edit
0
0
apache-2.0
d2be7c861e979d444b4f39aa8167d99fe93ad812
songchenwen/zhuanlan-rss,songchenwen/zhuanlan-rss
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar express = require('express');\n\n// Create our app\nvar app = express();\nconst PORT = process.env.PORT || 3100;\n\napp.use(function (req, resp, next) {\n if(req.headers['x-forwarded-proto'] === 'http') {\n next;\n }\n el...
javascript
edit
0
2
mit
c4083f8e755c4041521a4eb86c53b37afb763650
JulianNicholls/Complete-React-Web-App,JulianNicholls/Complete-React-Web-App
React-Weather/server.js
rejected_duplicate
Near-duplicate of sample 93491
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport { EditAnnotationCommand } from 'substance'\nimport SpellError from './SpellError'\nimport CorrectionTool from './CorrectionTool'\nimport SpellCheckCommand from './SpellCheckCommand'\n\nexport default {\n name: 'spell-check',\n ...
javascript
edit
0
1
mit
788d50fbb1c9699ec23feb1473533682795e2e5e
philschatz/substance-editor,substance/examples,substance/demos,substance/demos,philschatz/substance-editor,substance/examples
spell-check/spell-check/SpellCheckPackage.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n\"use strict\";\n\nconst express = require(\"express\");\nconst app = express();\n\nconst isProduction = process.env.NODE_ENV === \"production\";\n\n/* MIDDLEWARE */\n\napp\n .use(require(\"helmet\")())\n .use(require(\"compression\")...
javascript
edit
0
1
mit
dd664ae88ab3f6ae1dd1115eabf42f8b4c33da04
mrm8488/errorGiphy-service
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nconst TEST_TYPE = ((argv) => {\n let match = argv[argv.length - 1].match(/npm\\/test-(\\w+).js/);\n\n return match && match[1] || '';\n})(process.argv);\n\nfunction configOverrides(testType) {\n switch (testType) {\n cas...
javascript
edit
0
3
apache-2.0
99225bd1f8ed576667481070fad8f4aa1afa4083
postmanlabs/postman-sandbox
.nycrc.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\nvar angularMeteorSession = angular.module('angular-meteor.session', []);\n\nangularMeteorSession.factory('$session', [\n function () {\n return function (session) {\n\n return {\n\n bind: function(scope, m...
javascript
edit
0
1
mit
74b23bce6658e8319385489082d62d6bf2dec886
dtruel/angular-meteor,nweat/angular-meteor,omer72/angular-meteor,dszczyt/angular-meteor,DAB0mB/angular-meteor,mushkab/angular-meteor,dj0nes/angular-meteor,craigmcdonald/angular-meteor,Unavi/angular-meteor,hoalongntc/angular-meteor,kyroskoh/angular-meteor,nweat/angular-meteor,evanliomain/angular-meteor,IgorMinar/angular...
modules/angular-meteor-session.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nvar bind = require('function-bind');\nvar define = require('define-properties');\nvar replace = bind.call(Function.call, String.prototype.replace);\n\nvar leftWhitespace = /^[\\x09\\x0A\\x0B\\x0C\\x0D\\x20\\xA0\\u1680\\...
javascript
edit
0
1
mit
089bae49bd99ac3a6e07b99a158833a1c04bc609
ljharb/String.prototype.trimLeft,es-shims/String.prototype.trimLeft
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar path = require('path'),\n static = require('serve-static');\n\nmodule.exports = {\n setup: function (app, assetpath, options) {\n\n if (arguments.length === 2 && typeof assetpath === 'object') {\n options = a...
javascript
edit
0
6
mit
0ec63333975eb707437ba81a387603a501986204
UKHomeOffice/govuk-template-compiler,UKHomeOffice/govuk-template-compiler
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nimport { NativeEventEmitter, NativeModules } from 'react-native';\nconst { RNPusherPushNotifications } = NativeModules\nconst rnPusherPushNotificationsEmitter = new NativeEventEmitter(RNPusherPushNotifications)\n\nexpor...
javascript
edit
0
2
mit
2c9a03f34f0b455b3e77188d43bd8ee19d4865c0
b8ne/react-native-pusher-push-notifications,b8ne/react-native-pusher-push-notifications,b8ne/react-native-pusher-push-notifications
index.js
rejected_duplicate
Near-duplicate of sample 78736
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/* eslint-env node */\n'use strict';\n\nmodule.exports = {\n name: require('./package').name,\n\n included() {\n this._super.included.apply(this, arguments);\n\n const addonOptions =\n (this.app.options && this.app.options....
javascript
edit
0
6
mit
6c1fb37aa14bd0f413723e7a9708908ac920bb73
edgycircle/ember-pikaday,edgycircle/ember-pikaday
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nmodule.exports = {\n plugins: [\n [require('babel-plugin-dotenv'), {\n replacedModuleName: 'react-native-dotenv'\n }],\n ],\n};\n\n```\n\nApply this change: Use RN’s projectRoots resolver to set the correct configDir" }, ...
javascript
edit
0
0
mit
06d5aad8f3ed5115e2b9383d4f8e60bc18fd7879
zetachang/react-native-dotenv
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict'\n\nvar window = require('global/window')\nvar document = require('global/document')\nvar toArray = require('to-array')\n\nvar PREFIXES = /-(webkit|ms)-/\n\nmodule.exports = detectVendorPrefix()\n\nfunction detectVendorPrefi...
javascript
edit
0
3
mit
5369b87c490c727c1f7d4613ec2042093fba40e3
bendrucker/css-vendor-prefix
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n\"use strict\";\n\nvar charsNumbers = '0123456789';\nvar charsLower = 'abcdefghijklmnopqrstuvwxyz';\nvar charsUpper = charsLower.toUpperCase();\n\nvar chars = charsNumbers + charsLower + charsUpper;\n\nexports.generate = function(le...
javascript
edit
0
4
mit
f3b2a55115983a7fd3069da12016fb723c99c436
pcarranzav/node-randomstring,prashantgupta24/node-randomstring,prashantgupta24/node-randomstring,klughammer/node-randomstring
lib/randomstring.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\njQuery(function($) {\n $('.tabify .tabs a').bind('click', function() {\n var href = $(this).attr('href');\n var tabContent = $(href);\n $('.tabify .tabs a').removeClass('active'); // clear the active tabs\n $('.tabify .tabs...
javascript
edit
0
2
apache-2.0
9a56548ee32a661bf8d00d81e781f84aca90f3d9
j00bar/django-widgy,j00bar/django-widgy,j00bar/django-widgy
widgy/contrib/page_builder/static/widgy/page_builder/tabs.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar path = require('path');\n\nmodule.exports = {\n context: path.join(__dirname, \"src\"),\n\n entry: { main: \"./main\" },\n devtool: \"source-map\",\n output: {\n path: path.join(__dirname, \"dist\"),\n file...
javascript
edit
0
0
mit
a798a511b3c1b07f0259b3de5385d96d76d53ab1
mathijsco/rpi-alarm-clock,mathijsco/rpi-alarm-clock
webpack.config.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\nvar generators = require('yeoman-generator');\n\nmodule.exports = generators.Base.extend({\n writing: function () {\n this.fs.copy(\n this.templatePath('babelrc'),\n this.destinationPath('.babelrc')\n );\...
javascript
edit
0
2
mit
dde0aa06ac0105cfd3ffe9999299557485419b2a
canercandan/generator-node,zckrs/generator-node,yeoman/generator-node,RobertJGabriel/generator-node,iamstarkov/generator-node,thehobbit85/generator-node,rhettl/generator-node,davewasmer/generator-node,stevemao/generator-node
generators/babel/index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar ytdl = require('youtube-dl-vimeo');\nvar url = 'http://vimeo.com/93491987';\nvar echojs = require('echojs');\nvar fs = require('fs'),\nrequest = require('superagent');\n\nvar echo = echojs({\n key: process.env.ECHONEST_KEY\n});\n\n...
javascript
edit
0
2
mit
c01d0aa33a17673aaf36958cbfd6ade43de2b4e9
tamarasaurus/vimeo-song-extractor
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar es = require('event-stream');\nvar path = require('path');\nvar gutil = require('gulp-util');\nvar concat = require('gulp-concat');\nvar header = require('gulp-header');\nvar footer = require('gulp-footer');\nvar PluginError = gutil...
javascript
edit
0
5
mit
a44f704ef36adfca6b3e1dafde176e080ec31b88
sahat/gulp-angular-templatecache,stevemao/gulp-angular-templatecache,RobertoUa/gulp-angular-templatecache,miickel/gulp-angular-templatecache,samouss/gulp-angular-templatecache,Agnitio/gulp-agnitio-templatecache,eanakashima/gulp-angular-templatecache,AOEpeople/gulp-angular-templatecache
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n// Load the node-ffi extensions\nrequire('./ffi-extend')\n\n// The main exports is the casting function\nmodule.exports = $\n$._ = $ // legacy. TODO: remove by 0.1.0\n\n// export the exports from the 'import' module\nvar Import = requir...
javascript
edit
0
4
mit
4dae59ce2eb3109bfb92f91bdbb73452832e8386
mralexgray/NodObjC,telerik/NodObjC,jerson/NodObjC,TooTallNate/NodObjC,telerik/NodObjC,jerson/NodObjC,mralexgray/NodObjC,TooTallNate/NodObjC,jerson/NodObjC
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\nvar pkg = require('./package');\nvar gutil = require('gulp-util');\nvar through = require('through2');\nvar path = require('path');\nvar File = require('vinyl');\n\n// consts\nmodule.exports = function(out, options) {\n\n...
javascript
edit
0
7
mit
f37d480f62aeecec1411d09ea5376a49efe06739
cjroth/gulp-filelist
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict'\n\nvar parseURI = require('parse-uri')\nvar encode = require('punycode2/encode')\n\n// Illegal characters (anything which is not in between the square brackets):\nvar ILLEGALS = /[^a-z0-9\\:\\/\\?\\#\\[\\]\\@\\!\\$\\&\\'\\(...
javascript
edit
0
10
mit
81892ec9770fd275b7553c2d8ca1809fac663dd4
Kikobeats/is-uri
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nexports.create = function(logger) {\n\n return function(req, res, next) {\n var rEnd = res.end;\n\n // To track response time\n req._rlStartTime = new Date();\n\n // Setup the key-value object of data to log and include som...
javascript
edit
0
3
mit
72b6af5892e290be8b9e512200d65e6f13fc741b
mathrawka/express-request-logger
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n#!/usr/bin/env node\n\n\"use strict\";\n\nconst moment = require(\"moment\");\nconst sugar = require(\"sugar\");\nconst chalk = require(\"chalk\");\nconst exec = require(\"child_process\").exec;\n\n// Throw a fatal error\nconst fatal = ...
javascript
edit
0
2
mit
5b2f98301ccac135f01d75365a4ca0ebb3be0ee2
sam3d/git-date
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nmodule.exports = function() {\n var args = Array.prototype.slice.call(arguments);\n var cursor = args[0];\n var keys = args.slice(1);\n\n for(var i = 0; i < keys.length; i++) {\n cursor = cursor[keys[i]];\n if (cursor =...
javascript
edit
0
3
mit
981f2c73ecfa784ef48401c357a2ef0d9994eea8
artemshitov/nested-or-nothing
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nvar fnToStr = Function.prototype.toString;\n\nmodule.exports = function isCallable(value) {\n\ttry {\n\t\tfnToStr.call(value);\n\t\treturn true;\n\t} catch (e) {\n\t\treturn false;\n\t}\n};\n\n```\n\nApply this change: ...
javascript
edit
0
3
mit
b88d5439f1859c931f6cc6a0c34884a5e308a062
ljharb/is-callable
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar Tokenizer = require(\"tokenizer\")\n\nmodule.exports = function (cb) {\n var t = new Tokenizer(cb)\n\n t.addRule(/^:([A-Za-z_=+\\-*&?!$%|<>][A-Za-z0-9_=+\\-*&?!$%|<>]*)$/, \"keyword\")\n t.addRule(/^([A-Za-z_=+\\-*&?!$%|<>][A-Za-...
javascript
edit
0
2
mit
93b5c63191b81b2120a2abece7d9e7ffd0c3c15f
alanshaw/cljs-tokenizer
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar toc = require('markdown-toc');\n\nmodule.exports = {\n book: {\n assets: './assets',\n css: [\n \"atoc.css\"\n ],\n js: [\n \"atoc.js\"\n ]\n },\n hooks: {\n \"page:before\": fu...
javascript
edit
0
1
mit
f1340ce3eb931f2ce27ca98702c731f0891dcab0
willin/gitbook-plugin-atoc
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/**\n * mSupply Mobile\n * Sustainable Solutions (NZ) Ltd. 2019\n */\n\nimport Realm from 'realm';\n\n/**\n * An abstract object which contains metadata describing an indicator row or column.\n *\n * @property {string} id\n ...
javascript
edit
0
1
mit
3c8307c4b8ef02718e51b3be5a32f85265d1cb81
sussol/mobile,sussol/mobile,sussol/mobile,sussol/mobile
src/database/DataTypes/IndicatorAttribute.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict'\n\nvar standard = require('standard')\nvar format = require('util').format\nvar loaderUtils = require('loader-utils')\nvar snazzy = require('snazzy')\n\nmodule.exports = function standardLoader (text) {\n var self = this\n...
javascript
edit
0
5
isc
f75efd55f26db31e6756b60d33f5272fbcfc4815
timoxley/standard-loader
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nvar extend = require('xtend');\n\n\nvar fillopts = function (wrapped, opts) {\n opts = extend(wrapped.opts, opts);\n wrapped = wrapped.wrapped || wrapped;\n\n var fn = function (callOpts /*, args... */) {\n ...
javascript
edit
0
4
mit
c48218ea641c8002161d4888ccf976d75886f516
matthewwithanm/fillopts.js
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nconst config = require('./config.json');\nconst fs = require('fs');\n\nconst http = require('http');\nconst https = require('https');\n\nlet httpsOptions = {\n key: fs.readFileSync(config.keyPath, 'ascii'),\n cert: fs...
javascript
edit
0
1
mit
d94fd84076a2f845706e78bd854aba036e241aed
Thristhart/node-private-wiki,Thristhart/node-private-wiki
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nconst {BABEL_ENV, NODE_ENV} = process.env\n\nconst defaultOptions = {\n lodash: true,\n modules: BABEL_ENV === 'cjs' || NODE_ENV === 'test' ? 'commonjs' : false,\n targets: {\n browsers: ['IE 11', 'last 2 Edge versions', 'Firefox ...
javascript
edit
0
2
mit
b2e361497f5acd23a045645d203146267d580604
kensho/babel-preset-kensho,kensho/babel-preset-kensho
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar server = require('json-server')\n\nvar port = process.env.PORT || 3000 \n\nfunction reset() {\n server.low.load('data.json')\n}\n\nserver.low.autoSave = false\nserver.low.on('update', reset)\nserver.low.on('remove', reset)\nserver....
javascript
edit
0
1
mit
e17b329d34d9b0261377fc4112b2bd593c46ac03
AlicePerez/jsonplaceholder,typicode/jsonplaceholder,AlicePerez/jsonplaceholder,typicode/jsonplaceholder
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport Ember from 'ember';\nimport setupMirage from '../helpers/setup-mirage';\nimport { moduleFor, test } from 'ember-qunit';\n\nconst {\n run\n} = Ember;\n\nmoduleFor('copyable', 'Integration | Copyable | failure', {\n integration: ...
javascript
edit
0
2
mit
a22b55c93d40b07910ea22d3c903063698893919
offirgolan/ember-data-copyable,offirgolan/ember-data-copyable
tests/integration/copyable-failure-test.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n\"use strict\";\nconst express = require('express');\nconst twilio = require('twilio');\nconst bodyParser = require('body-parser');\n\nconst app = express();\n\n// Run server to listen on port 8000.\nconst server = app.listen(8000, () =...
javascript
edit
0
2
mit
77caf524416e2a5daef15472b37f437ef961d74d
sagnew/SentimentRocket,sagnew/SentimentRocket
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\nconst dargs = require('dargs');\nconst execa = require('execa');\nconst gutil = require('gulp-util');\nconst through = require('through2');\n\nmodule.exports = opts => {\n\topts = Object.assign({\n\t\tcolors: true,\n\t\ts...
javascript
edit
0
2
mit
83735a6415aca2964ce2fcf28bc61ff93de06714
sindresorhus/gulp-mocha
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n\"use strict\"\n\nvar rules = {\n \"no-yield-in-race\": require(\"./lib/rules/no-yield-in-race\"),\n \"yield-effects\": require(\"./lib/rules/yield-effects\"),\n \"no-unhandled-errors\": require(\"./lib/rules/no-unhandled-errors\")\n...
javascript
edit
0
1
mit
7457c9b3ec14e6f9f72fcd6ef8f5c5c07d921ef1
pke/eslint-plugin-redux-saga
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport Ember from 'ember';\n\nconst { $ } = Ember;\n\nexport default Ember.Route.extend({\n model() {\n return $.getJSON('/telling-stories/acceptance.json');\n },\n\n setupController(controller, model) {\n this._super(...argume...
javascript
edit
0
1
mit
4e4b986e344224dc9f59d31525251ceabfbf242c
mvdwg/telling-stories-dashboard,mvdwg/telling-stories-dashboard
addon/routes/stories.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/* global L */\n'use strict';\nvar gju = require('geojson-utils');\n\nvar leafletPip = {\n bassackwards: false,\n pointInLayer: function(p, layer, first) {\n if (p instanceof L.LatLng) p = [p.lng, p.lat];\n else if (...
javascript
edit
0
6
bsd-2-clause
e76cfdc064cfe3d29ab01eebe2d4ad9b35564129
mapbox/leaflet-pip,mapbox/leaflet-pip
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict'\nimport React, { Children } from 'react'\nimport classNames from 'classnames'\n\n/* eslint-disable react/prop-types */\nexport default function Box (props) {\n const c = classNames('box', props.className)\n\n const conten...
javascript
edit
0
4
isc
34b50de60554eda90c9790efe9f6ef1c06c2ac6e
passcod/kitr-box
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nvar cheerio = require('cheerio');\n\nmodule.exports = function (html, options) {\n var results = {};\n var $ = cheerio.load(html);\n\n results.hrefs = [];\n\n $('link').each(function (index, element) {\n ...
javascript
edit
0
4
mit
d3885e12a7f5cb0926727d6ed1393d3b4268e63d
jonkemp/inline-css,jonkemp/inline-css
packages/list-stylesheets/index.js
rejected_duplicate
Near-duplicate of sample 79781
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n// this proxy will route requests to /api to backend\n// and all the other requests to frontend\n\nconst backendDevServerPort = 8080;\nconst frontendDevServerPort = 3000;\nconst portThatProxyListensOn = 9000;\n\nconst http = require(\"h...
javascript
edit
0
2
apache-2.0
1006db2254a7a22e62032a16eff4914896b038db
googleinterns/step250-2020,googleinterns/step250-2020,googleinterns/step250-2020,googleinterns/step250-2020
reverse-proxy/index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\ndescribe('angularBasicAuthExample.login module', function() {\n var scope;\n\n // Mock unavailable modules\n angular.module('ngMessages', []);\n angular.module('angularBasicAuthExample.user', []);\n\n beforeEach(mo...
javascript
edit
0
1
mit
e2358c8b41c32dd9bfaa1afe444b418a258fbd5a
jessamynsmith/angular-basic-auth-example,jessamynsmith/angular-basic-auth-example
app/login/login_test.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar debug = require( 'debug' )( 'wpcom-vip' );\nvar Request = require( './lib/util/request' );\n\n// Modules\n\n\nfunction WPCOM_VIP( token ) {\n this.req = new Request( this );\n\n this.auth = {};\n}\n\nWPCOM_VIP.protot...
javascript
edit
0
1
mit
a1ba7b4aa86ba21e3cf452f99d836ef838759892
Automattic/vip-js-sdk
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nvar path = require('path');\n\nexports.routes = function() {\n\n var appPath = path.resolve(__dirname + '/public');\n\n return {\n\n 'get' : {\n // get routes\n '/<%= _.slugify(appTitl...
javascript
edit
0
1
mit
626a5b1cb7009b1148762473a25ade30020ed7a3
greaterweb/generator-edgeplate,greaterweb/generator-edgeplate
app/templates/routes.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/*\n * CSSMIN: Compress CSS files\n */\nmodule.exports = {\n /*\n * TARGET: Concats and minified library css\n */\n installLibCss: {\n options: {\n compatibility: 'ie8',\n relativeTo: 'css/',\...
javascript
edit
0
0
mit
26f895209cf3f7d45d8d22a8d770f7867cb1e6e6
bywatersolutions/reports-site,HonzaMikula/bolt,HonzaMikula/bolt,HonzaMikula/bolt,bywatersolutions/reports-site,GDmac/bolt,skript-cc/bolt,GDmac/bolt,HonzaMikula/bolt,bywatersolutions/reports-site,bywatersolutions/reports-site,GDmac/bolt,skript-cc/bolt,skript-cc/bolt,skript-cc/bolt,GDmac/bolt
app/src/grunt/cssmin.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar async = require('async'),\n\tboom = require('boom'),\n\tdefaultData = {'success' : true};\n\nfunction Series(arr) {\n\tthis.arr = arr;\n}\n\nfunction Validate(arr) {\n\tvar len = arr.length;\n\twhile(len--) {\n\t\tif(typeof arr[len]...
javascript
edit
0
3
mit
9071bae445df046df93e7ec09b288bebb487e672
Pranay92/hapi-next
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar express = require('express');\nvar app = express();\n\nvar request = require('request');\nvar cheerio = require('cheerio');\n\napp.get('/', function(req, res) {\n res.sendFile('./consume.html', {\"root\": __dirname})\n});\n\nvar po...
javascript
edit
0
1
mit
c01dd906a844ca895cb101034d77781347641637
valgaze/CAFAPI,valgaze/CAFAPI
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nexports = module.exports = function(IoC, store, logger) {\n var flowstate = require('flowstate');\n \n \n var dispatcher = new flowstate.Manager(store);\n \n return Promise.resolve(dispatcher)\n .then(function(dispatcher) {\n ...
javascript
edit
0
1
mit
6b41493209f9a4de89d770e04f19d88e350ddbc9
bixbyjs/bixby-express
app/state/dispatcher.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nvar getYouTubeID = require('get-youtube-id');\n\nmodule.exports = function(url){\n var id = getYouTubeID(url);\n\n return {\n default: {\n url: 'http://img.youtube.com/vi/' + id + '/default.jpg',\n width:...
javascript
edit
0
3
mit
8d79fc58fa664e513a6d7805c78a1c3edbc1cab7
matiassingers/youtube-thumbnail
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nvar assert = require('assert'),\n Batch = require('batch'),\n getStylesData = require('style-data'),\n getStylesheetList = require('list-stylesheets'),\n getHrefContent = require('href-content');\n\nmodule.e...
javascript
edit
0
2
mit
7a71a7d998fb8cf1753b278641f245da9fad7fd9
jonkemp/extract-css,jonkemp/extract-css
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n//handles message function\nvar SubmitView = Backbone.View.extend({\n\n events: {\n 'submit' : 'handleSubmit',\n 'change #lang' : 'changeLanguage',\n 'click #roomButton' : 'changeRoom'\n },\n\n initialize: function(){},\n\n ...
javascript
edit
0
2
mit
422ddba1eb472b1bb413730ae5dbcff6820105ca
leeric92/HumpbackSeahorses,leeric92/HumpbackSeahorses,leeric92/HumpbackSeahorses
public/client/views/SubmitView.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/*global require, module*/\n/*!\n * missing-keys <https://github.com/tobiasoberrauch/missing-keys>\n *\n * Copyright (c) 2015, Tobias Oberrauch.\n * Licensed under the MIT License.\n */\n\n'use strict';\n\n(function (factory) {\n if (t...
javascript
edit
0
5
mit
45fe6e8f8e67d87792d3f806e53ca522c2818f69
tobiasoberrauch/missing-keys,tobiasoberrauch/missing-keys
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nmodule.exports = class PivotBuffer {\n constructor(size) {\n this.size = size;\n this.$buffer = new Buffer(size);\n \n this.$buffer.fill(0);\n\n this.$curSize = 0;\n }\n \n ...
javascript
edit
0
3
isc
561a249225136d29874cef810d924ea913b86d5a
yotamofek/pivot-buffer
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar inputContext = input.RegisterInputContextRaw(\"fpsMouseLook\", 150);\ninputContext.SetTakeMouseEventsOverQt(true);\ninputContext.MouseEventReceived.connect(MouseEvent);\n\nfunction MouseEvent(event)\n{\n // Press RMB\n if (eve...
javascript
edit
0
13
apache-2.0
ddc9b6f32c48f8938656060e9d41568bdbe4c9a5
realXtend/tundra,pharos3d/tundra,BogusCurry/tundra,jesterKing/naali,jesterKing/naali,AlphaStaxLLC/tundra,AlphaStaxLLC/tundra,realXtend/tundra,antont/tundra,antont/tundra,AlphaStaxLLC/tundra,jesterKing/naali,jesterKing/naali,jesterKing/naali,BogusCurry/tundra,BogusCurry/tundra,antont/tundra,BogusCurry/tundra,realXtend/t...
bin/jsmodules/startup/FirstPersonMouseLook.js
rejected_complexity
Cyclomatic complexity too high: 13
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nTemplate.postsList.helpers({\n posts: function() {\n return Posts.find();\n }\n});\n\n```\n\nApply this change: Order posts by submitted time." }, { "role": "assistant", "content": "Template.postsList.helpers({\n posts...
javascript
edit
0
1
mit
feff95896d5d0168943a5ef727733df371f99932
drainpip/music-management-system,drainpip/music-management-system
app/client/templates/posts/posts_list.js
rejected_duplicate
Near-duplicate of sample 71801
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar CLIEngine = require('eslint').CLIEngine;\nvar chalk = require('chalk');\nvar cli = new CLIEngine({});\nvar format = '';\n\nmodule.exports = function (paths, options) {\n if (options && options.formatter) {\n format = options.for...
javascript
edit
0
4
mit
a7526ee754f0646e0a8a98bdf8e59caca4c88a95
BadgeLabs/mocha-eslint,eagleeye/mocha-eslint
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nconst fs = require('fs');\n\nconst WebClient = require('@slack/client').WebClient;\n\nconst token = require('./config.js').apiToken;\n\nconst message = process.argv[2];\n\nconst web = new WebClient(token);\nweb.chat.pos...
javascript
edit
0
2
mit
342e76e4791f6c194f745972b7d84cb908522573
thegazelle-ad/slack-deployment-bot
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/*\n * Initialize Bolt module\n */\nvar Bolt = {};\n\n```\n\nApply this change: Improve Bolt module doc block" }, { "role": "assistant", "content": "/*\n * Initialize the Bolt module\n *\n * @type {Object}\n * @module Bolt\n...
javascript
edit
0
0
mit
cc0e880d7577f4078a0e8ea3153bfb25285830a6
nikgo/bolt,nantunes/bolt,GawainLynch/bolt,romulo1984/bolt,Eiskis/bolt-base,marcin-piela/bolt,hannesl/bolt,tekjava/bolt,Intendit/bolt,joshuan/bolt,hugin2005/bolt,GawainLynch/bolt,bywatersolutions/reports-site,Eiskis/bolt-base,codesman/bolt,electrolinux/bolt,lenvanessen/bolt,hannesl/bolt,richardhinkamp/bolt,Calinou/bolt,...
app/src/js/bolt.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/* Main app file for CEL project\n * Mostly stolen from requirejs examples: http://requirejs.org/docs/api.html\n */\n\n'use strict';\n\nrequirejs.config({\n //except, if the module ID starts with 'app',\n //load it from the js/app...
javascript
edit
0
2
mit
4be3d3d3d94fcc34c50c0eda5e106c2e932a9637
smartchicago/chicago-early-learning,smartchicago/chicago-early-learning,smartchicago/chicago-early-learning,smartchicago/chicago-early-learning
python/ecep/portal/static/js/main.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nmodule.exports = {\n\tModel: require('./src/model'),\n\tDocument: require('./src/document'),\n\tQuery: require('./src/query'),\n\tMemStore: require('./src/mem-store'),\n\tMemSource: require('./src/mem-source')\n}\n```\n\nApply this chan...
javascript
edit
0
0
mit
1514d3e6fd33951cb1b9dc9539481b07f2aac8a9
dstreet/polymod
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar Twitter = require('twode'),\n _ = require('underscore'),\n CronJob = require('cron').CronJob;\n config = require('./lib/config'),\n fs = require(\"fs\"),\n readFile = fs.readFileSync(\"./data/FY2016Q1.json\", \"UTF-8\...
javascript
edit
0
3
mit
d6c58b39e3a54551f04418a15ddb3e5780fe8bd8
PunkChameleon/FiscalPhilly
index.js
rejected_duplicate
Near-duplicate of sample 72254
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nmodule.exports = compressible\n\ncompressible.specs =\ncompressible.specifications = require('./specifications.json')\n\ncompressible.regex\ncompressible.regexp = /json|text|javascript|dart|ecmascript|xml|x-font-ttf|ms-opentype|ms-fonto...
javascript
edit
0
2
mit
0559b29996b305e9ccc962481cd701738fb99222
jshttp/compressible
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nmodule.exports = function parse(value){\n if(isTemplateString(value)){\n var parameter = Parameter(value);\n\n var template = function (context){\n if(typeof context === \"undefined\"){\n context = {};\n }\n ...
javascript
edit
0
3
mit
abafe0e72c5ab492bd3a0954814c8a2cd7471f22
datavis-tech/json-templates
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar React = require('react/addons');\n\nvar Notfication = React.createClass({\n\n /**\n * @function hide\n * @description Focus on the element.\n */\n open: function () {\n this.setState({\n active: true\n });\n },\n...
javascript
edit
0
1
mit
67099a049459f6b28c463a67cc9fafc2c55dba6c
pburtchaell/react-notification
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\nconst pMap = require('p-map');\n\nconst filter = filterer => (x, i) => Promise.resolve(filterer(x, i)).then(val => {\n\tif (!val) {\n\t\tconst err = new Error();\n\t\terr.code = 'EISFALSE';\n\t\tthrow err;\n\t}\n\n\tretur...
javascript
edit
0
2
mit
52ed256422cade997948ac7ecaa590b3126ea14d
kevva/p-every,kevva/p-every
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/* jshint node: true */\n'use strict';\n\nmodule.exports = {\n name: 'ember-g-map'\n};\n\n```\n\nApply this change: Load google-map lib on page load" }, { "role": "assistant", "content": "/* jshint node: true */\n'use stric...
javascript
edit
0
6
mit
a5ff474542c4bb1a837e2b744fe50a934506dad6
asennikov/ember-g-map,moeabm/ember-g-map,asennikov/ember-g-map,moeabm/ember-g-map
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nvar fs = require('fs');\nvar pictureTube = require('picture-tube');\nvar webshot = require('webshot');\n\nfunction hitThat (url, options) {\n var name = Date.now() + '_that.png';\n var o = options || {};\n if (o.widt...
javascript
edit
0
6
mit
5b614add11ee48f9067f9002ce64d2778285ff3c
bevacqua/hit-that
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/* @flow */\n\nimport React, { Component } from 'react';\nimport { NativeModules } from 'react-native';\n\nexport default class KeepAwake extends Component {\n\n static isActive = false;\n\n static activate() {\n if (!KeepAwake.i...
javascript
edit
0
2
mit
dbf91b468a8f00f34373f6186ad8ebe0c8cb7c3a
corbt/react-native-keep-awake,corbt/react-native-keep-awake,corbt/react-native-keep-awake
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nconst isBoolean = require('is-boolean')\nconst isFunction = require('is-function')\n\nconst doWheil = (d0, wh1le) => {\n if (!isFunction(d0)) { throw new TypeError('d0 is no function!, D0 MUST BE A FUNCTION') }\n if (!isBoolean(wh1le)...
javascript
edit
0
6
mit
4d33f7861d4b602f546adb1780c1af695b81ce8c
subsidel/do-whiel
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/* jshint node: true */\n'use strict';\n\nvar fs = require('fs');\nvar path = require('path');\nvar merge = require('lodash-node/modern/object/merge');\nvar template = require('lodash-node/modern/string/template');\n\nmodule.exports = {...
javascript
edit
0
5
mit
b412c3a319b0d698528524772bb0433d56901fc5
davewasmer/ember-cli-rollbar,davewasmer/ember-cli-rollbar,davewasmer/ember-cli-rollbar
index.js
accepted
null
true