conversations listlengths 2 3 | source stringclasses 1
value | stack stringclasses 1
value |
|---|---|---|
[
{
"from": "system",
"value": "Fix error stack trace for browsers\n"
},
{
"from": "human",
"value": "var util = require('util');\n\n\nvar APIError = function(name, message, status, requestInfo, originalError){\n this.name = name || this.constructor.name || this.constructor.prototype.name || '';\... | javascript | chosen |
[
{
"from": "system",
"value": "Remove unnecessary setup of pluralize and singularize."
},
{
"from": "human",
"value": "import Orbit from '../../src';\nimport { Promise } from 'rsvp';\n\nOrbit.Promise = Promise;\n\nOrbit.pluralize = function(original) {\n return original.match(/s$/) ? original : ... | javascript | chosen |
[
{
"from": "system",
"value": "Create a user record for validation purposes.\n\nThe test is missing because I'm having a very hard time\nrunning a unit test that will return a user instance.\nFor reasons unknown to me, the returned instance in the test\nlooks like \"Class\".\n"
},
{
"from": "human",
... | javascript | chosen |
[
{
"from": "system",
"value": "Test for Express no longer needs debug lines\n"
},
{
"from": "human",
"value": "console.log('lord');\nvar express = require('express');\n\nconsole.log('hey');\nvar app = express();\n\nconsole.log('ok');\n\napp.get('/', function(req, res){\n\tconsole.log('yay', res.r... | javascript | chosen |
[
{
"from": "system",
"value": "Add missing private variable to isArray\n"
},
{
"from": "human",
"value": "/**\n * Tests whether or not an object is an array.\n *\n * @private\n * @category Internal\n * @param {*} val The object to test.\n * @return {boolean} `true` if `val` is an array, `false` o... | javascript | chosen |
[
{
"from": "system",
"value": "Add scan AP step to test case.\n"
},
{
"from": "human",
"value": "var SoftAPSetup = require('../index');\nvar sap = new SoftAPSetup();\n\nconsole.log(\"Requesting public key...\");\nsap.publicKey(configure);\n\nfunction configure(err, dat) {\n\n\tif(err) { throw err... | javascript | chosen |
[
{
"from": "system",
"value": "Uploads: Migrate old FS and GridFS store names\n"
},
{
"from": "human",
"value": "RocketChat.Migrations.add({\n\tversion: 96,\n\tup() {\n\t\tconst query = {\n\t\t\t$or: [{\n\t\t\t\t's3.path': {\n\t\t\t\t\t$exists: true\n\t\t\t\t}\n\t\t\t}, {\n\t\t\t\t'googleCloudSto... | javascript | chosen |
[
{
"from": "system",
"value": "Configure loader to store assets in clear names instead of hash\n"
},
{
"from": "human",
"value": "\n'use strict';\n\nvar path = require('path');\nvar webpack = require('webpack');\nvar HtmlWebpackPlugin = require('html-webpack-plugin');\nvar ExtractTextPlugin = req... | javascript | chosen |
[
{
"from": "system",
"value": "Change the library export name.\n"
},
{
"from": "human",
"value": "const fs = require('fs');\nconst merge = require('webpack-merge');\nconst path = require('path');\nconst webpack = require('webpack');\n\nconst common = {\n entry: './src/index.js',\n output: {\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Revert \"Externalize Shifty and Lodash\"\n\nThis reverts commit ebc2fd169272b7bfec9ae2fbdf4e1ef4fb52b7cd.\n\nThis is fixes the fact that Rekapi will not load properly in web\nenvironments if the dependencies are not bundled into the binary. This\nmay not be ideal and warrants ... | javascript | chosen |
[
{
"from": "system",
"value": "Change to package.json to enable source map\n"
},
{
"from": "human",
"value": "var path = require('path');\nvar webpack = require('webpack');\nvar configFile = require('./settings/config.json');\n\nmodule.exports = {\n entry: [\n path.resolve(__dirname, 'app... | javascript | chosen |
[
{
"from": "system",
"value": "[1.9] Put Components.utils to a constant\n\nhttp://code.google.com/p/fbug/source/detail?r=11472\n"
},
{
"from": "human",
"value": "/* See license.txt for terms of usage */\n\ndefine([], function() {\n\n// *************************************************************... | javascript | chosen |
[
{
"from": "system",
"value": "Allow deepAssign to delete props.\n\n"
},
{
"from": "human",
"value": "import { readAsArrayBuffer } from 'pouchdb-binary-utils';\n\nexport function bufferToHexString(buffer) {\n const hexCodes = [];\n const view = new DataView(buffer);\n\n for (let i = 0; i... | javascript | chosen |
[
{
"from": "system",
"value": "Load configuration from current directory\n"
},
{
"from": "human",
"value": "var fs = require('fs');\nvar MongoClient = require('mongodb').MongoClient;\n\nvar config = require('../front/config.json');\n\nMongoClient.connect(config.mongodb, function(err, db) {\n i... | javascript | chosen |
[
{
"from": "system",
"value": "Rename ShoppingList1Controller -> ShoppingListController. Edit comment\n"
},
{
"from": "human",
"value": "// app.shoppingList1.controller.js\n\n(function() {\n \"use strict\";\n\n angular.module(\"ShoppingList\")\n .controller(\"ShoppingList1Controller\", Shopp... | javascript | chosen |
[
{
"from": "system",
"value": "Add possibility for a fallback\n"
},
{
"from": "human",
"value": "const duration = require('@maxdome/duration');\nconst Throttle = require('redis-throttle');\n\nmodule.exports = config => {\n Throttle.configure(config);\n return (key, limit, callback) => {\n le... | javascript | chosen |
[
{
"from": "system",
"value": "Make to draw by dragging\n"
},
{
"from": "human",
"value": "(function(){\n colors = ['#eeeeee', '#d6e685', '#8cc665', '#44a340', '#1e6823'];\n days = document.getElementsByClassName('day');\n Array.prototype.forEach.call(days, function(element) {\n element.add... | javascript | chosen |
[
{
"from": "system",
"value": "Use Firebase instance (or now called this.context) to check user authentication status and display sign-in or sign-out button accordingly\n"
},
{
"from": "human",
"value": "import React from 'react';\nimport './styles/App.css';\nimport TravelObject from './component... | javascript | chosen |
[
{
"from": "system",
"value": "Use spaces instead of tabs\n"
},
{
"from": "human",
"value": "var express = require('express');\nvar app = express();\nvar bodyParser = require('body-parser');\n\napp.set('port', (process.env.PORT || 5000));\napp.use(bodyParser.json());\n\napp.get('/', function(req,... | javascript | chosen |
[
{
"from": "system",
"value": "Replace .call with a normal method call (faster)\n\nIt's faster to call methods directly instead of using `.call` and assigning a scope yourself"
},
{
"from": "human",
"value": "var EngineIO = require(\"engine.io\")\nvar EventEmitter = require(\"events\").EventEmitt... | javascript | chosen |
[
{
"from": "system",
"value": "Add merge-conflict extension to postInstall\n"
},
{
"from": "human",
"value": "/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT ... | javascript | chosen |
[
{
"from": "system",
"value": "Fix og:site_name and add lang attribute on the content\n"
},
{
"from": "human",
"value": "import React, { Component } from \"react\"\nimport { PropTypes } from \"react\"\nimport Helmet from \"react-helmet\"\n\nimport Header from \"Header\"\nimport Footer from \"Foot... | javascript | chosen |
[
{
"from": "system",
"value": "Clear database before running tests\n"
},
{
"from": "human",
"value": "\nvar new_browser = require('./browser').new_browser;\n\nexports.check_title = function(test) {\n\n var browser = new_browser();\n\n test.expect(1);\n\n browser\n .waitForTextPres... | javascript | chosen |
[
{
"from": "system",
"value": "Create a gulp tdd target\n"
},
{
"from": "human",
"value": "var gulp = require('gulp');\nvar concat = require('gulp-concat');\nvar uglify = require('gulp-uglify');\nvar rename = require('gulp-rename');\nvar template = require('gulp-template');\nvar KarmaServer = req... | javascript | chosen |
[
{
"from": "system",
"value": "Switch absolute path from root dir in gulp setup\n"
},
{
"from": "human",
"value": "var gulp = require('gulp');\n\ngulp.task('default', function() {\n gulp.src('css/*.css')\n .pipe(concat('app.min.css'))\n .pipe(gulp.dest('dist/'));\n});\n\n// TODO:... | javascript | chosen |
[
{
"from": "system",
"value": "Set default text type to copy content inside selection.\n"
},
{
"from": "human",
"value": "import { XMLSchema } from 'substance'\nimport SheetSchemaData from '../../tmp/SheetSchema.data'\n\nconst SheetSchema = XMLSchema.fromJSON(SheetSchemaData)\n\n// TODO: this sho... | javascript | chosen |
[
{
"from": "system",
"value": "Fix issue where load script was failing in ie8.\n"
},
{
"from": "human",
"value": "define([], function () {\n /**\n * A loader for Javascript <script/> tags\n */\n function LoadScript () {\n\n var script, head,\n onLoadHandler,\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Add test helper to extract the alpha channel from an image data array\n"
},
{
"from": "human",
"value": "beforeEach(function() {\n this.addMatchers({\n toBeLessThan: function(expected) {\n return this.actual < expected;\n },\n toHaveAllValuesInRange: ... | javascript | chosen |
[
{
"from": "system",
"value": "Fix signature of metadata change event\n\nAll events are expected to pass model and options. This is required to\nmake it work with Scrolled's `watchCollection`.\n\nREDMINE-19303\n"
},
{
"from": "human",
"value": "import _ from 'underscore';\nimport {Configuration} ... | javascript | chosen |
[
{
"from": "system",
"value": "[reference] Store add method to load references.\n"
},
{
"from": "human",
"value": "//Dependencies.\nvar CoreStore = require('../CoreStore');\nvar buildDefinition = require('./definition');\n/**\n * Class standing for the reference store.\n */\nclass ReferenceStore ... | javascript | chosen |
[
{
"from": "system",
"value": "Use flowstate components for state storage.\n"
},
{
"from": "human",
"value": "exports = module.exports = function(serializeClientCb, deserializeClientCb, s) {\n var StateStore = require('../lib/txn/state');\n \n var store = new StateStore(s);\n store.serializeC... | javascript | chosen |
[
{
"from": "system",
"value": "ENYO-2069: Enable accessibility mode for moonstone-extra builds.\n\nEnyo-DCO-1.1-Signed-off-by: Aaron Tam <aaron.tam@lge.com>\n"
},
{
"from": "human",
"value": "var\n\tready = require('enyo/ready');\n\nvar\n\tstrawman = require('./src');\n\nready(function () {\n\tva... | javascript | chosen |
[
{
"from": "system",
"value": "Move script to seperate file"
},
{
"from": "human",
"value": "$(document).ready(function(){\n // Twitter Bootstrap hack for menus on touch device\n $('body').on('touchstart.dropdown', '.dropdown-menu', function (e) { e.stopPropagation(); });\n\t\n $('a[rel=... | javascript | chosen |
[
{
"from": "system",
"value": "Make Home a stateful component to make hotreload demo work\n"
},
{
"from": "human",
"value": "import React from 'react';\nimport {Link} from 'react-router';\n\nexport default () => (\n <div>\n <h1>Hello world!</h1>\n <Link to=\"/other\">other</Link>\n </div>... | javascript | chosen |
[
{
"from": "system",
"value": "Move dynamic chunks step before uglify step\n\nThis ensures that uglify will catch these changes."
},
{
"from": "human",
"value": "import { ConcatSource } from 'webpack-sources'\n\nexport default class DynamicChunksPlugin {\n apply (compiler) {\n const isImportC... | javascript | chosen |
[
{
"from": "system",
"value": "Update for new Massive version"
},
{
"from": "human",
"value": "// database connection instance\nmodule.exports = {\n conn: function(){\n return require(\"massive\").connectSync({\n connectionString : \"postgres://databaseuser:password@host/database\" // if... | javascript | chosen |
[
{
"from": "system",
"value": "Fix initial action to include a type\n"
},
{
"from": "human",
"value": "import {\n BehaviorSubject,\n ReplaySubject\n} from 'rx'\n\nexport default function createDispatcher() {\n const dispatcher = new ReplaySubject()\n dispatcher.onNext(null) // Initialisation ... | javascript | chosen |
[
{
"from": "system",
"value": "Fix typo in createFlight action\n"
},
{
"from": "human",
"value": "import Marty from \"marty\";\nimport OrderConstants from \"../constants/orderConstants.js\";\n\nclass OrderActionCreators extends Marty.ActionCreators {\n creatFlight(flight, orderId, options) {\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Use config for test AWS client.\n"
},
{
"from": "human",
"value": "var AWS = require('aws-sdk')\n\n// Load environment variables from .env file.\nrequire('dotenv-extended').load()\n\nAWS.config.update({\n region: process.env.AWS_REGION,\n endpoint: process.env.DYN... | javascript | chosen |
[
{
"from": "system",
"value": "Revert \"Test Commit for Test App.\"\n\nThis reverts commit 26a8c46efb6317158581c71a06e137a11494942f.\n"
},
{
"from": "human",
"value": "'use strict';\n\n/**\n * Module dependencies. Test commit\n */\nvar mongoose = require('mongoose'),\n passport = require('pass... | javascript | chosen |
[
{
"from": "system",
"value": "Fix bug that dropped RSS item titles\n"
},
{
"from": "human",
"value": "\"use strict\";\n\nvar components = require(\"server-components\");\nvar truncateHtml = require(\"truncate-html\");\nvar moment = require(\"moment\");\n\nvar feedparser = require('feedparser-pro... | javascript | chosen |
[
{
"from": "system",
"value": "Hide Nunjucks warnings from the dev console\n"
},
{
"from": "human",
"value": "'use strict';\n\nconst path = require('path');\nconst fractal = module.exports = require('@frctl/fractal').create();\nconst pkg = require(path.join(__dirname, 'package.json'));\n\nfractal... | javascript | chosen |
[
{
"from": "system",
"value": "[test-studio] Add a test case for selecting array items for preview\n"
},
{
"from": "human",
"value": "import icon from 'react-icons/lib/fa/recycle'\n\nexport default {\n name: 'referenceTest',\n type: 'document',\n title: 'Reference test',\n description: 'Test ... | javascript | chosen |
[
{
"from": "system",
"value": "fix(logout): Make logout 'clear' the screen.\n"
},
{
"from": "human",
"value": "import React from 'react'\nimport { useAuth } from 'use-auth0-hooks'\n\nimport NavLoginButton from './nav-login-button'\n\n/**\n * This component wraps NavLoginButton with Auth0 informat... | javascript | chosen |
[
{
"from": "system",
"value": "Store OpenSeadragon.Viewer instantiation object handle\n"
},
{
"from": "human",
"value": "//= require openseadragon\n\n(function($) {\n var __osd_counter = 0;\n function generateOsdId() {\n __osd_counter++;\n \n return \"Openseadragon\" + __osd_counter;\n... | javascript | chosen |
[
{
"from": "system",
"value": "[CSA-996] Hide the spellcheck view when querying, not just when results come back. [rev: matthew.gordon]\n"
},
{
"from": "human",
"value": "/*\n * Copyright 2014-2016 Hewlett-Packard Development Company, L.P.\n * Licensed under the MIT License (the \"License\"); you... | javascript | chosen |
[
{
"from": "system",
"value": "Add _format when constructing store.query request\n"
},
{
"from": "human",
"value": "import Ember from \"ember\";\nimport DS from \"ember-data\";\n\nconst {\n get,\n inject: { service }\n} = Ember;\n\nexport default DS.JSONAPIAdapter.extend({\n namespace: 'api',\... | javascript | chosen |
[
{
"from": "system",
"value": "tests/acceptance/page-not-found: Use Mirage.js instead of Polly.js\n"
},
{
"from": "human",
"value": "import { visit, currentURL } from '@ember/test-helpers';\nimport { setupApplicationTest } from 'ember-qunit';\nimport { module, test } from 'qunit';\n\nimport { set... | javascript | chosen |
[
{
"from": "system",
"value": "[WEB-819] Add required validation to prescription account type\n"
},
{
"from": "human",
"value": "import * as yup from 'yup';\nimport i18next from '../../core/language';\n\nconst t = i18next.t.bind(i18next);\n\nexport default yup.object().shape({\n type: yup.string... | javascript | chosen |
[
{
"from": "system",
"value": "Support primitive arrays for class local fields\n"
},
{
"from": "human",
"value": "'use babel';\n\nfunction getClassLocalFields(tokens, editor) {\n return tokens\n .map(row => row.filter(token =>\n !token.scopes.includes('meta.method.body.java') &&\n t... | javascript | chosen |
[
{
"from": "system",
"value": "Make this a bit clearer.\n"
},
{
"from": "human",
"value": "var convert = require('convert-source-map');\r\nvar type = require('../file-type');\r\n\r\nfunction getComment(map, fileType) {\r\n\r\n var mapConverter = convert.fromObject(map);\r\n\r\n switch (file... | javascript | chosen |
[
{
"from": "system",
"value": "Update env - only load dotenv in development\n"
},
{
"from": "human",
"value": "'use strict';\n\nvar express = require('express');\nvar routes = require('./app/routes/index.js');\nvar mongoose = require('mongoose');\nvar passport = require('passport');\nvar session ... | javascript | chosen |
[
{
"from": "system",
"value": "Add HTML IDs to CloseDialogConfirmation\n"
},
{
"from": "human",
"value": "import React from 'react'\nimport PropTypes from 'prop-types'\n\nimport { Modal, Button } from 'react-bootstrap'\n\nimport style from './style.css'\n\nconst CloseDialogConfirmation = ({ onYes... | javascript | chosen |
[
{
"from": "system",
"value": "refactor: Remove info about special changeset\n"
},
{
"from": "human",
"value": "import React, { Component} from 'react'\nimport serializeForm from 'form-serialize'\n\nexport class ChangesetForm extends Component {\n state = {\n value: ''\n }\n\n constructor(p... | javascript | chosen |
[
{
"from": "system",
"value": "Change install directory for dev to mocks dir\n"
},
{
"from": "human",
"value": "var\n env = process.env.NODE_ENV || 'development',\n config;\n\nconfig = {\n production : {\n db : {\n URL : process.env['wac_service_mongodb_url']\n },\n componentsURL... | javascript | chosen |
[
{
"from": "system",
"value": "Fix graphs on dashboard not working\n"
},
{
"from": "human",
"value": "import { do_plot_json } from \"../components/chart\";\nimport { setupTimeline } from \"../components/timeline\";\nimport { setupGlobeByClass } from \"../components/globe\";\nimport { setupTippy }... | javascript | chosen |
[
{
"from": "system",
"value": "Add shebang and set execute bit.\n"
},
{
"from": "human",
"value": "/*\n ___ usage ___ en_US ___\n usage: prolific <protocol> <protocol args>\n\n --help display this message\n\n ___ $ ___ en_US ___\n\n udp is required:... | javascript | chosen |
[
{
"from": "system",
"value": "fix(app): Change dev server port to be the same than instructions\n"
},
{
"from": "human",
"value": "'use strict';\n\nlet webpack = require('webpack');\nlet WebpackDevServer = require('webpack-dev-server');\nlet config = require('./config/webpack.config.js');\n\ncon... | javascript | chosen |
[
{
"from": "system",
"value": "Remove testing for unused nextDouble() function\n"
},
{
"from": "human",
"value": "/**\n * No Description\n *\n * @author Erik E. Lorenz <erik@tuvero.de>\n * @license MIT License\n * @see LICENSE\n */\n\n/*\n * Random Test\n */\ndefine(function() {\n return functio... | javascript | chosen |
[
{
"from": "system",
"value": "Fix a bug with bad names used as query selectors.\n"
},
{
"from": "human",
"value": "/**\n * Utility functions.\n */\n\nfunction serializeToJSON(arr) {\n // Convert form data to a proper json value\n var json = {};\n $.each(arr, function(_, pair){\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Switch Taint to util/arg for argument validation\n"
},
{
"from": "human",
"value": "/**\n * @file Taint item.\n * @package\n */\n\n'use strict'\n\n// Imports\nconst Address = require('./address')\n\n/**\n * Private members store.\n * @private\n */\nconst privs = new... | javascript | chosen |
[
{
"from": "system",
"value": "Fix login callbackUrl on production\n"
},
{
"from": "human",
"value": "import passport from 'passport';\nimport { Strategy } from 'passport-helsinki';\n\nimport serverConfig from './config';\n\nfunction configurePassport() {\n let helsinkiStrategy;\n helsinkiStrat... | javascript | chosen |
[
{
"from": "system",
"value": "Add hasOwnProperty check before trying to delete\n"
},
{
"from": "human",
"value": "var path = require('path');\nvar url = require('url');\nvar messages = require('./messages');\nvar ports = {};\n\nvar getSnippet = function (hostIp, socketIoPort, scriptPort) {\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Include only fields that a component needs\n"
},
{
"from": "human",
"value": "var Appbase = require('appbase-js');\n\nmodule.exports = {\n\tgetRequestObject: function (config, fieldName, boundingBoxCoordinates) {\n var geo_bounding_box = JSON.parse(`{\"${fieldNam... | javascript | chosen |
[
{
"from": "system",
"value": "Remove deprecated API call from sold tickets admin page\n"
},
{
"from": "human",
"value": "function short_hash(data, type, row, meta)\n{\n return data.substring(0,7);\n}\n\nfunction init_page()\n{\n $('#tickets').dataTable({\n \"ajax\": '/tickets/ajax/t... | javascript | chosen |
[
{
"from": "system",
"value": "Make sure not to set auth header to null\n"
},
{
"from": "human",
"value": "import { router } from '../../main';\nimport URLS from '../../urls';\n\nexport default {\n user: {\n authenticated: false\n },\n getProfile: localStorage.getItem('profile'),\n login(c... | javascript | chosen |
[
{
"from": "system",
"value": "Modify example server request params\n"
},
{
"from": "human",
"value": "'use strict';\n\nconst express = require('express');\nconst MsgQueueClient = require('msgqueue-client');\n\nconst mqServerConfig = require('../common/config/mqserver.js');\nconst config = requir... | javascript | chosen |
[
{
"from": "system",
"value": "Fix issue with Chrome + Travis & setuid...\n"
},
{
"from": "human",
"value": "/* eslint-env node */\nmodule.exports = {\n test_page: 'tests/index.html?hidepassed',\n disable_watching: true,\n launch_in_ci: [\n 'Chrome'\n ],\n launch_in_dev: [\n 'Chrome'\n... | javascript | chosen |
[
{
"from": "system",
"value": "Allow passing in environment-variables from webpack\n\nTo pass variables, include `loaders: {env: {…}}` in your web pack config\n"
},
{
"from": "human",
"value": "var compiler = require('./lib/compiler');\n\nmodule.exports = function(content) {\n\tthis.cacheable();\... | javascript | chosen |
[
{
"from": "system",
"value": "Support the console.log() API when using syslog.\n"
},
{
"from": "human",
"value": "if ( process.argv.indexOf( \"--console\" ) !== -1 ) {\n\tmodule.exports = {\n\t\tinit: function() {\n\t\t\treturn console;\n\t\t}\n\t};\n\treturn;\n}\n\nvar syslog = require( \"node-... | javascript | chosen |
[
{
"from": "system",
"value": "Send users his total hours for a specific day\n"
},
{
"from": "human",
"value": "'use strict';\n\nconst config = require('../config')\n\nmodule.exports = function(controller) {\n\n const apiai = require('../apiai')({token: config.apiAiToken})\n\n controller.middle... | javascript | chosen |
[
{
"from": "system",
"value": "Create default options response only if there is not one.\n"
},
{
"from": "human",
"value": "var methods = ['GET', 'POST', 'HEAD', 'PUT', 'DEL', 'PATCH', 'OPTS'];\n\nvar Base = function(app) {\n\tthis.route = null;\n\tthis.setup(app);\n\tthis.routeSetup(app);\n};\n\... | javascript | chosen |
[
{
"from": "system",
"value": "Fix typo in debugging comment\n"
},
{
"from": "human",
"value": "// namespace\nvar App = App || {};\n\nApp.WebSocketState = (function () {\n \"use strict\";\n\n console.log(\"WebSocketState.create Compiling ...\");\n var fn = function (game) {\n Phas... | javascript | chosen |
[
{
"from": "system",
"value": "Update aggregate definition, groupby not required.\n"
},
{
"from": "human",
"value": "export default {\n \"type\": \"Aggregate\",\n \"metadata\": {\"generates\": true, \"changes\": true},\n \"params\": [\n { \"name\": \"groupby\", \"type\": \"field\", \"array\... | javascript | chosen |
[
{
"from": "system",
"value": "Add prompt when an updated service worker is found.\n"
},
{
"from": "human",
"value": "if ('serviceWorker' in navigator) {\n navigator.serviceWorker.register('offline-worker.js').then(function(registration) {\n console.log('offline worker registered');\n });\n}... | javascript | chosen |
[
{
"from": "system",
"value": "Fix scrollbar update with ref util\n"
},
{
"from": "human",
"value": "import FluidGeminiScrollbar from '../components/FluidGeminiScrollbar';\n\nlet scrollbarWidth = null;\n\nconst ScrollbarUtil = {\n /**\n * Taken from Gemini's source code with some edits\n * h... | javascript | chosen |
[
{
"from": "system",
"value": "Include copyright notice in JS comments.\n"
},
{
"from": "human",
"value": "/*!\n * Shopping List\n * http://github.com/eheikes/shopping-list\n * License: Apache-2.0\n */\nangular.module('shoppingList', ['ngSanitize', 'ui.select', 'ng.group']).config(\n ['uiSelectC... | javascript | chosen |
[
{
"from": "system",
"value": "Fix Ember 2.1 initializer deprecation\n"
},
{
"from": "human",
"value": "import AdminStore from 'ember-admin/stores/admin';\n\nexport function initialize(registry, app) {\n registry.register('store:admin', AdminStore);\n app.inject('route', 'admin', 'service:admin... | javascript | chosen |
[
{
"from": "system",
"value": "Correct blocmetrics route to include v1\n"
},
{
"from": "human",
"value": "var elements = document.getElementsByTagName('script')\n\nArray.prototype.forEach.call(elements, function(element) {\n if (element.type.indexOf('math/tex') != -1) {\n // Extract math mar... | javascript | chosen |
[
{
"from": "system",
"value": "Fix setting locale to the proper variable\n"
},
{
"from": "human",
"value": "import Ember from 'ember';\n\nimport OSFAgnosticAuthRouteMixin from 'ember-osf/mixins/osf-agnostic-auth-route';\nimport AnalyticsMixin from '../mixins/analytics-mixin';\n\nexport default Em... | javascript | chosen |
[
{
"from": "system",
"value": "Add a login svc and url\n"
},
{
"from": "human",
"value": "/**\n * Created by Caleb on 9/25/2014.\n */\n(function () {\n angular.module('fc.login').config([\n '$stateProvider',\n '$urlRouterProvider',\n routeConfig\n ]);\n\n function ro... | javascript | chosen |
[
{
"from": "system",
"value": "Clean up unused error handling.\n"
},
{
"from": "human",
"value": "#!/usr/bin/env node\n\nconst cli = require('commander')\nconst pkg = require('../package')\nconst apiCall = require('./apiCall')\n\ncli.name('ur-cli')\n\ncli\n .version(pkg.version).usage('<command>... | javascript | chosen |
[
{
"from": "system",
"value": "Set initial focused option item\n"
},
{
"from": "human",
"value": "var $ = require('jquery');\n\nmodule.exports = {\n\n\t$doc: $(document),\n\n\tsetupDom: function () {\n\n\t\tthis.$el = $(this.element);\n\n\t\tthis.$el.addClass(this.options.classes.originalSelect);... | javascript | chosen |
[
{
"from": "system",
"value": "Store as a whole document instead of individual rows as it can get really expensive\n"
},
{
"from": "human",
"value": "var async = require('async');\nvar AWS = require('aws-sdk');\nrequire('dotenv').config();\n\nAWS.config.update({\n region: process.env.AWS_REGION\... | javascript | chosen |
[
{
"from": "system",
"value": "Set redirect and alias config before starting app\n"
},
{
"from": "human",
"value": "import Vue from 'vue';\nimport VueRouter from 'vue-router';\nimport VueForm from 'vue-form';\nimport { sync } from 'vuex-router-sync';\n\nimport store from './vuex/store.js';\nimpor... | javascript | chosen |
[
{
"from": "system",
"value": "Use markdown default classes for footnotes\n\nFirst step in the process of fixing the footnotes\n"
},
{
"from": "human",
"value": "// Smooth Scroll\nsmoothScroll.init({\n speed: 800,\n easing: 'easeInOutCubic',\n updateURL: false,\n offset: 125\n});\n\n/... | javascript | chosen |
[
{
"from": "system",
"value": "Hide Jobs admin pages from users\n"
},
{
"from": "human",
"value": "'use strict';\n\n// Configuring the Articles module\nangular.module('jobs').run(['Menus',\n\tfunction(Menus) {\n\t\t// Set top bar menu items\n\t\tMenus.addMenuItem('topbar', 'Jobs', 'jobs', 'dropdo... | javascript | chosen |
[
{
"from": "system",
"value": "Clean up small formatting glitch\n"
},
{
"from": "human",
"value": "pwi_form = function() {\nvar $viewerSelected = 'fancybox',\nsettings = {\n username: 'brianc@palaver.net',\n popupPlugin: $viewerSelected,\n showPhotoDownload: true,\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Add test for SliceTiming negative value detection\n"
},
{
"from": "human",
"value": "var assert = require('assert');\nvar validate = require('../index');\n\ndescribe('JSON', function(){\n\n\tvar file = {\n\t\tname: 'task-rest_bold.json',\n\t\trelativePath: '/task-... | javascript | chosen |
[
{
"from": "system",
"value": "Fix for using defaultClickHandler in pages that do not have Backbone.history\ninitialized.\n"
},
{
"from": "human",
"value": "/*\n Add a default clickhandler so we can use hrefs\n */\nBackbone.View.prototype.defaultClickHandler = function( e ) {\n if ( e.metaKey ... | javascript | chosen |
[
{
"from": "system",
"value": "Remove --harmony_symbols, Symbol works without a flag\n"
},
{
"from": "human",
"value": "'use strict';\n\nvar findup = require('findup-sync');\nvar spawnSync = require('child_process').spawnSync;\nvar gruntPath = findup('node_modules/grunt-cli/bin/grunt', {cwd: __di... | javascript | chosen |
[
{
"from": "system",
"value": "Print errors to STDERR instead of STDOUT\n"
},
{
"from": "human",
"value": "'use strict';\n\nvar configLoader = require('./config-loader');\nvar LessHint = require('./lesshint');\nvar meow = require('meow');\n\nmodule.exports = function () {\n var config;\n va... | javascript | chosen |
[
{
"from": "system",
"value": "Fix selected month to show correct selected month"
},
{
"from": "human",
"value": "\"use strict\";\n\nimport Ember from \"ember\";\nimport moment from \"moment\";\n\nconst DAYSINTOMONTH = 7;\n\nexport default Ember.Mixin.create({\n queryParams: ['month'],\n\n mon... | javascript | chosen |
[
{
"from": "system",
"value": "chore(release): Check that RELEASE_TOKEN is set\n\n[#96495576]\n"
},
{
"from": "human",
"value": "import {map} from 'event-stream';\nimport gulp from 'gulp';\nimport {addReleaseNotesToTag} from './helpers/github-service';\nimport {log} from 'gulp-util';\n\nconst plu... | javascript | chosen |
[
{
"from": "system",
"value": "Fix snapshot fail on new Node.js 12.6\n"
},
{
"from": "human",
"value": "#!/usr/bin/env node\n\nlet Server = require('../../server')\n\nlet app = new Server({\n subprotocol: '1.0.0',\n supports: '1.x'\n})\napp.nodeId = 'server:FnXaqDxY'\n\napp.on('fatal', e => con... | javascript | chosen |
[
{
"from": "system",
"value": "Fix message passing for newer Chrome version\n\nOnly use `chrome.extension.sendMessage` if available.\nUse `chrome.runtime.sendMessage` otherwise.\n"
},
{
"from": "human",
"value": "(function() {\n /**\n * Iterates over each link found on a Feedly page emiting it... | javascript | chosen |
[
{
"from": "system",
"value": "Add schedules collection to backend\n\nSigned-off-by: Juan Martin Runge <2e19f93fe0d263e6ab743b7b04f5a1b612584839@gmail.com>\n"
},
{
"from": "human",
"value": "var mbc = require('mbc-common'),\n collections = mbc.config.Common.Collections,\n back... | javascript | chosen |
[
{
"from": "system",
"value": "examples: Add notice of openshift 2 shutdown\n\nReferences:\n\n * Issue: https://github.com/yagop/node-telegram-bot-api/issues/426\n"
},
{
"from": "human",
"value": "/**\n * This example demonstrates setting up webhook\n * on the OpenShift platform.\n */\n\n\nconst... | javascript | chosen |
[
{
"from": "system",
"value": "Add \"Loading...\" text to editor window.\n"
},
{
"from": "human",
"value": "function browseSuccess(r, stat, jqXHR) {\n $('#editor-panel').html(r);\n $('.igt-panel').each(function(index, elem) {\n $(elem).panel({\n title: 'Instance '+$(elem).... | javascript | chosen |
[
{
"from": "system",
"value": "Use querySelectorAll instead of recursing.\n"
},
{
"from": "human",
"value": "var selection = window.getSelection();\nvar urls = [];\n\nfunction get_links(node) {\n var i;\n var child;\n var children;\n\n if (!node) {\n return;\n }\n\n children = node.child... | javascript | chosen |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.