conversations listlengths 2 3 | source stringclasses 1
value | stack stringclasses 1
value |
|---|---|---|
[
{
"from": "system",
"value": "Move import inside the runtime call\n"
},
{
"from": "human",
"value": "/* jshint node: true */\n'use strict';\nmodule.exports = function(sequelize, DataTypes) {\n var Exercise = require('./exercise')(sequelize, DataTypes);\n\n var Set = sequelize.define('Set', {\n... | javascript | chosen |
[
{
"from": "system",
"value": "Add simple connect button handler to connect to default robot\n"
},
{
"from": "human",
"value": "// top-level container\nimport React from 'react'\nimport {connect} from 'react-redux'\n\nimport {\n NAME as ROBOT_NAME,\n actions as robotActions,\n selectors as rob... | javascript | chosen |
[
{
"from": "system",
"value": "Fix MODULESTATE_REPLACE bug: checked for a member literally called 'module', rather than for a member named according to the content of module.\n"
},
{
"from": "human",
"value": "import { routerReducer as routing } from 'react-router-redux';\nimport { reducer as for... | javascript | chosen |
[
{
"from": "system",
"value": "Use keys filter in nestedMenuCollection\n\nWe are accessing `all[label]` here twice - trying to solve this with a\nvariable set through ng-init doesn't work, as ng-init will also resolve\nafter this tag has been processed (at least that's what I think). If we\nwant to access th... | javascript | chosen |
[
{
"from": "system",
"value": "Remove unnecessary logic in Action helper\n"
},
{
"from": "human",
"value": "var _ = require('lodash-node');\n\nvar Action = function(name, two, three, four) {\n var options, run, helpers;\n\n // Syntax .extend('action#method', function() { ... }, {})\n if ( type... | javascript | chosen |
[
{
"from": "system",
"value": "Fix the default LDAP properties to match the configuration documentation.\n"
},
{
"from": "human",
"value": "#!/usr/bin/env node\n//\n// NodeJS script that implements an authentication daemon for eJabberd.\n//\n'use strict';\n\nvar assert = require('assert'),\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Allow version check to actually run on older node versions\n"
},
{
"from": "human",
"value": "#!/usr/bin/env node\n\n/* eslint-disable strict */\n/* eslint-disable no-console */\n/* eslint-disable prefer-template */\n\n'use strict';\n\n// A simple check that node + ... | javascript | chosen |
[
{
"from": "system",
"value": "Add some more comments to the example\n"
},
{
"from": "human",
"value": "/*\n A bot that welcomes new guild members when they join\n*/\n\n// Import the discord.js module\nconst Discord = require('discord.js');\n\n// Create an instance of a Discord Client\nconst cli... | javascript | chosen |
[
{
"from": "system",
"value": "Initialize OL6 view projection with OL2 one\n"
},
{
"from": "human",
"value": "import { mainLizmap, mainEventDispatcher } from '../modules/Globals.js';\nimport olMap from 'ol/Map';\nimport View from 'ol/View';\n\n/** Class initializing Openlayers Map. */\nexport def... | javascript | chosen |
[
{
"from": "system",
"value": "Clear flashed messages on reset\n"
},
{
"from": "human",
"value": "$('#send').submit(function(e) {\n\t$('.flash').text(\"\");\n\tvar name = $('#name').val();\n\tvar email = $('#email').val();\n\tvar text = $('#text').val();\n\n\tif (name && email && text) {\n\t\tcon... | javascript | chosen |
[
{
"from": "system",
"value": "Resolve scope issues with save function callback\n"
},
{
"from": "human",
"value": "angular.module('ChillaxApp', [])\n\t.controller(\"ChillaxController\", function () {\n\t\n\tvar chillax = this;\n \n chillax.init = function() {\n chillax.nextNotifi... | javascript | chosen |
[
{
"from": "system",
"value": "Revert \"fix: Fix to import the browser version of document-register-element.\"\n\nThis reverts commit 6254538340e9e0390f03fa810f5c06404e36e48f.\n"
},
{
"from": "human",
"value": "// We load the Safari fix before document-register-element because DRE\n// overrides a... | javascript | chosen |
[
{
"from": "system",
"value": "Delete init code (mount App)\n"
},
{
"from": "human",
"value": "import React from 'react';\nimport ReactDOM from 'react-dom';\n\nimport {\n Router,\n Route,\n IndexRoute,\n browserHistory\n} from 'react-router';\n\nimport './index.css';\n\nimport App from './App... | javascript | chosen |
[
{
"from": "system",
"value": "Change command title and placeholder\n"
},
{
"from": "human",
"value": "define([\n \"text!src/templates/file.html\",\n \"less!src/stylesheets/main.less\"\n], function(fileTemplate) {\n var _ = codebox.require(\"hr/utils\");\n var commands = codebox.requi... | javascript | chosen |
[
{
"from": "system",
"value": "Use the correct API to register the Popup class\n"
},
{
"from": "human",
"value": "import { NetworkRack, User } from 'kinvey-js-sdk/dist/export';\nimport Kinvey from 'kinvey-html5-sdk';\nimport { HttpMiddleware } from './middleware';\nimport Popup from './popup';\ni... | javascript | chosen |
[
{
"from": "system",
"value": "Tweak re-export syntax for better output\n"
},
{
"from": "human",
"value": "export {configureStore, createDefaultMiddleware} from \"./configureStore\";\n\nimport createNextState from \"immer\";\nimport {combineReducers} from \"redux\";\n\nexport {\n createNextSta... | javascript | chosen |
[
{
"from": "system",
"value": "Exclude some package meta from POT files.\n"
},
{
"from": "human",
"value": "module.exports = {\n\tpackage: {\n\t\toptions: {\n\t\t\tcwd: '<%= paths.tmp %>',\n\t\t\texclude: [\n\t\t\t\t'includes/back-compat\\.php'\n\t\t\t],\n\t\t\tpotHeaders: {\n\t\t\t\t'language': ... | javascript | chosen |
[
{
"from": "system",
"value": "Fix linting issue with Posts\n"
},
{
"from": "human",
"value": "import React, { PropTypes } from 'react'\nimport { Link } from 'react-router'\nimport styles from './index.module.css'\n\nfunction Posts (props) {\n const posts = props.posts.map((post) => {\n const... | javascript | chosen |
[
{
"from": "system",
"value": "refactor(listable): Allow override of options group name\n"
},
{
"from": "human",
"value": "\"use strict\";\n\nmodule.exports = listableOptions;\n\nfunction listableOptions(yargs) {\n return yargs.options({\n json: {\n group: \"Command Options:\",\n de... | javascript | chosen |
[
{
"from": "system",
"value": "Fix Windows Script Host error\n"
},
{
"from": "human",
"value": "//#!/usr/bin/env node\n\nconst cli = require(\"cli\");\nconst uglify = require(\"uglify-es\");\n\nconst readFile = require(\"../lib/read-file\");\nconst generator = require(\"../lib/generator\");\n\nco... | javascript | chosen |
[
{
"from": "system",
"value": "Add NewIdeaDialog state unit tests\n"
},
{
"from": "human",
"value": "/* eslint-env mocha, jest */\n\nimport getDefault from '../../shared/testUtils';\nimport NewIdeaDialog from '../NewIdeaDialog';\n\nconst defaultProps = {\n open: false,\n onRequestClose() {},\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Fix console error in IE"
},
{
"from": "human",
"value": "/* global console */\ndefine( function () {\n\t\n\t'use strict';\n\n\tif ( typeof console !== undefined && typeof console.warn === 'function' && typeof console.warn.apply === 'function' ) {\n\t\treturn functio... | javascript | chosen |
[
{
"from": "system",
"value": "Fix alingment problem with multiline inputs\n"
},
{
"from": "human",
"value": "import React from 'react'\nimport { Text, View } from 'react-native'\nimport styled from 'styled-components/native'\nimport defaultTheme from './theme'\n\nconst LabelWrapper = styled.View... | javascript | chosen |
[
{
"from": "system",
"value": "Add a few '-' cases\n"
},
{
"from": "human",
"value": "var assert = require('assert');\nvar domain = require('..');\n\ndescribe('domain-regex', function() {\n\n // https://publicsuffix.org/list/effective_tld_names.dat\n it('should handle a wide array of domains', ... | javascript | chosen |
[
{
"from": "system",
"value": "Test .get(key) resolves to value\n"
},
{
"from": "human",
"value": "import test from 'ava';\nimport Keyv from '../';\n\ntest('Keyv is a function', t => {\n\tt.is(typeof Keyv, 'function');\n});\n\ntest('Keyv cannot be invoked without \\'new\\'', t => {\n\tt.throws(()... | javascript | chosen |
[
{
"from": "system",
"value": "Add onRestarted listener, and restart app: crbug/167196, crbug/155221\n"
},
{
"from": "human",
"value": "/**\n * Listens for the app launching then creates the window\n *\n * @see http://developer.chrome.com/trunk/apps/app.runtime.html\n * @see http://developer.chro... | javascript | chosen |
[
{
"from": "system",
"value": "Add success and error events tests\n"
},
{
"from": "human",
"value": "/*global describe, it */\n\"use strict\";\n(function () {\n\n\tdescribe( \"$.fn.paginate()\", function () {\n\n\t\tit( \"should be defined\", function() {\n\t\t\texpect( $.fn.paginate ).to.be.a( \... | javascript | chosen |
[
{
"from": "system",
"value": "Return the agent id and the skill id\n"
},
{
"from": "human",
"value": "'use strict';\n\n/**\n *\n * @param data the result that came out from the history api getting recently (last 10) consumers conversations\n */\nfunction getAgentIdForBestConversationMCS (data) {... | javascript | chosen |
[
{
"from": "system",
"value": "Move projects dropdown to Bootstrap list-group\n"
},
{
"from": "human",
"value": "import React from 'react';\n\nconst Projects = props => {\n return (\n <ul className=\"projects\">\n {Object.keys(props.projects).map(projectId => {\n const ticket = pr... | javascript | chosen |
[
{
"from": "system",
"value": "Fix broken comment field in CfP\n"
},
{
"from": "human",
"value": "// This file is part of Indico.\n// Copyright (C) 2002 - 2019 CERN\n//\n// Indico is free software; you can redistribute it and/or\n// modify it under the terms of the MIT License; see the\n// LICENS... | javascript | chosen |
[
{
"from": "system",
"value": "Fix two crashes in performSubscriptionAction\n"
},
{
"from": "human",
"value": "import { Subscriptions } from './collection';\nimport { subscriptionTypes } from './schema'\nimport { runCallbacksAsync, newMutation } from 'meteor/vulcan:core';\nimport Users from 'mete... | javascript | chosen |
[
{
"from": "system",
"value": "Add util function to detect if an element is overflowing\n"
},
{
"from": "human",
"value": "export const getViewport = () => ({\n height: window.innerHeight || document.documentElement.offsetHeight,\n width: window.innerWidth || document.documentElement.offsetWidt... | javascript | chosen |
[
{
"from": "system",
"value": "Add a good and bad endpoint ... quick sanity checks\n"
},
{
"from": "human",
"value": "// EXPRESS ROUTES\n\nconst routes = require('express').Router();\nconst logger = require('../lib/logger')\n\nroutes.get('/game/:gameid', (req, res) => {\n //todo: check if the ... | javascript | chosen |
[
{
"from": "system",
"value": "Add operator presedence test in tests\n"
},
{
"from": "human",
"value": "// @description Number unit tests\nassert(3.0 == 3, \"Number equality\");\nassert(\"3\" == 3, \"Number and string equality\");\nassert(\"4\" !== 3, \"Number and string strict equality\");\nasse... | javascript | chosen |
[
{
"from": "system",
"value": "REMOVE unused computed property in ItemFIlter\n"
},
{
"from": "human",
"value": "var FilterService = require(\"services/ItemFilterService\");\nvar ResourceService = require(\"services/ResourceService\");\n\nVue.component(\"item-filter\", {\n\n props: [\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Enable deprecated-type rule in www\n\nSummary:\nEnable the rule and remove `flow strict-local` files with violations. (In a previous diff, we dealt with all `flow strict` files with violations).\n\nIn subsequent diffs will enable in other `.flowconfig`s\n\nbypass-lint\n\nReview... | javascript | chosen |
[
{
"from": "system",
"value": "Fix resizing issues with iframed pages\n"
},
{
"from": "human",
"value": "import React, { Component } from 'react'\nimport Helmet from 'react-helmet'\n\nimport { NavBar } from '../../components'\n\nconst styles = {\n iframe: {\n width: '100%',\n }\n}\n\nclass T... | javascript | chosen |
[
{
"from": "system",
"value": "Add catID url parameter to state\n"
},
{
"from": "human",
"value": "\nvar app = angular.module(\"browseApp.routes\", ['ui.router']);\n\n\napp.config(function($stateProvider, $urlRouterProvider) {\n\n $urlRouterProvider\n\n .otherwise('/categories');\n\n\n $... | javascript | chosen |
[
{
"from": "system",
"value": "Set spotlight inner angle to glTF defaults\n"
},
{
"from": "human",
"value": "const Signal = require('signals')\n\nfunction SpotLight (opts) {\n this.type = 'SpotLight'\n this.enabled = true\n this.changed = new Signal()\n this.target = [0, 0, 0]\n this.color =... | javascript | chosen |
[
{
"from": "system",
"value": "Make the example webpack build less noisy\n"
},
{
"from": "human",
"value": "import path from 'path'\nimport fs from 'fs'\nimport HtmlWebpackPlugin from 'html-webpack-plugin'\n\nmodule.exports = {\n entry: './app.js',\n output: {\n path: path.join(__dirname, 'd... | javascript | chosen |
[
{
"from": "system",
"value": "Rewrite JavaScript for website redesign\n"
},
{
"from": "human",
"value": "$(document).ready(function() {\n\n\t// Show/hide elements depending on window size\n\tif ($(window).width() <= 1024) {\n\t\t$(\"nav\").hide();\n\t} else if ($(window).width() > 1024) {\n\t\t$... | javascript | chosen |
[
{
"from": "system",
"value": "Use [].reduce instead of [].forEach :D\n"
},
{
"from": "human",
"value": "Array.prototype.sortBy = function(key){\n var get = Ember.get;\n\n return this.sort(function(a, b){\n return get(a, key) > get(b, key);\n });\n};\n\nArray.prototype.sum = function(){\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Fix missing default values with autocomplete\n"
},
{
"from": "human",
"value": "import { inject, bindable, bindingMode } from 'aurelia-framework';\nimport { Config } from 'aurelia-api';\n\n@inject(Element, Config)\nexport class UiAutocomplete {\n @bindable({defau... | javascript | chosen |
[
{
"from": "system",
"value": "Add listable composer to popuraFactory\n\n"
},
{
"from": "human",
"value": "import authenticable from './composers/authenticable';\nimport searchable from './composers/searchable';\n\nconst debug = require('debug')('popura:factory');\n\n/**\n * Factory function that... | javascript | chosen |
[
{
"from": "system",
"value": "Fix write on a read-only property\n"
},
{
"from": "human",
"value": "(function() {\n'use strict';\n\n// Inject SVG icons into the DOM\nvar element = document.createElement('div');\nelement.id = 'darkroom-icons';\nelement.style = 'height: 0; width: 0; position: absol... | javascript | chosen |
[
{
"from": "system",
"value": "Update format of welcome message and notification\n"
},
{
"from": "human",
"value": "let Config = require('../../config');\nlet url = require('url');\nlet webHook = url.resolve(Config.app.url, '/codeship/');\n\nclass FormatterService {\n\n\tformat(type, build) {\n\t... | javascript | chosen |
[
{
"from": "system",
"value": "Fix abbreviation list not showing\n"
},
{
"from": "human",
"value": "import React, { Component } from 'react';\nimport { Link } from 'react-router';\nimport Endpoints from './Endpoints';\nimport './styles/HeaderBoardList.css';\n\nclass HeaderBoardList extends Compon... | javascript | chosen |
[
{
"from": "system",
"value": "Add en_US translation as fallback\n"
},
{
"from": "human",
"value": "import translations from './translations/accessibility-cloud.js-widget/translations';\n\nfunction findLocaleWithCountry(localeWithoutCountry) {\n const regexp = new RegExp(`^${localeWithoutCountry... | javascript | chosen |
[
{
"from": "system",
"value": "Update loading of modules in main entry point\n"
},
{
"from": "human",
"value": "define('mygame', ['lyria/game', 'lyria/localization/group', 'mygame/achievements', 'mygame/scenelist', 'mygame/prefablist', 'mygame/assetlist', 'mygame/i18n', 'lyria/prefab/manager'], f... | javascript | chosen |
[
{
"from": "system",
"value": "Fix wrong MongoDB driver method name\n"
},
{
"from": "human",
"value": "'use strict';\n\n// Modify models\nconst upsert = function ({ collection, newData }) {\n const func = newData.length === 1 ? upsertOne : upsertMany;\n return func({ collection, newData });\n};... | javascript | chosen |
[
{
"from": "system",
"value": "Add colour to execution status.\n"
},
{
"from": "human",
"value": "#!/usr/bin/env node\n\nconst\n fs = require('fs')\n program = require('commander');\n\nprogram\n .version('0.0.1')\n .description('A command line script to minify files.')\n .option('-f, --... | javascript | chosen |
[
{
"from": "system",
"value": "Add url validation on frontend\n"
},
{
"from": "human",
"value": "import Ember from 'ember';\n\nexport default Ember.Component.extend({\n siteUrl: null,\n file: null,\n fileName: null,\n message: '',\n isSaving: false,\n actions:{\n startComplete: function(... | javascript | chosen |
[
{
"from": "system",
"value": "Fix \"Looks good\" unit test.\n"
},
{
"from": "human",
"value": "var React = require(\"react\");\nvar renderToDOMNode = require(\"../render-to-dom-node.js\");\nvar ReagicEditor = require(\"./reagic-editor.js\");\n\nclass EditorExample extends ReagicEditor {\n ren... | javascript | chosen |
[
{
"from": "system",
"value": "Implement Announce Banner for /benefit\n"
},
{
"from": "human",
"value": "import React from 'react';\nimport LinkButton from 'shared/components/linkButton/linkButton';\nimport Donate from 'shared/components/donate/donate';\nimport Join from 'shared/components/join/j... | javascript | chosen |
[
{
"from": "system",
"value": "Add authSecret to config vars\n"
},
{
"from": "human",
"value": "var log = require('../lib/logger');\n\nvar allTheSettings = {\n coinbaseApiKey: process.env.COINBASE_API_KEY,\n coinbaseApiSec: process.env.COINBASE_API_SECRET,\n coinbaseApiUri: process.env.COINBAS... | javascript | chosen |
[
{
"from": "system",
"value": "[CHORE] Remove ssh from ripple rest api endpoint.\n"
},
{
"from": "human",
"value": "var nconf = require('nconf');\n\nnconf\n .file({ file: './config/config.json' })\n .env();\n\nnconf.defaults({\n 'RIPPLE_REST_API': 'https://localhost:5990',\n 'DATABASE_URL': '... | javascript | chosen |
[
{
"from": "system",
"value": "Fix typo in migration. Didn't bother with new migration, nothing was ever deployed\n"
},
{
"from": "human",
"value": "'use strict'\nvar db = require('../app/db');\n\nexports.up = function(next) {\n db.Semester.create([\n \t{\n \t\tname: 'סתיז תשע\"ז', year: 2017,... | javascript | chosen |
[
{
"from": "system",
"value": "Use module.exports to ensure compatibility\n"
},
{
"from": "human",
"value": "import Submitter from './Submitter'\nimport SensorsAnalytics from './SensorsAnalytics'\n\nexport { Submitter }\nexport default SensorsAnalytics\n"
},
{
"from": "gpt",
"value": ... | javascript | chosen |
[
{
"from": "system",
"value": "Use a relative path for sign-up template.\n"
},
{
"from": "human",
"value": "{\n angular.module('marvelousnote.signUp')\n .directive('signUp', [\n\n '$state',\n 'UsersService',\n ($state, UsersService) => {\n\n class SignUpController {\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Remove reference to removed module\n"
},
{
"from": "human",
"value": "if (typeof AFRAME === 'undefined') {\n throw new Error('Component attempted to register before AFRAME was available.');\n}\n\n// Components\nrequire('./components/motion-capture-recorder.js');\nr... | javascript | chosen |
[
{
"from": "system",
"value": "Return the instance from jss.use()"
},
{
"from": "human",
"value": "'use strict'\n\nvar StyleSheet = require('./StyleSheet')\nvar Rule = require('./Rule')\nvar PluginsRegistry = require('./PluginsRegistry')\n\n/**\n * Jss constructor.\n *\n * @api public\n */\nfunct... | javascript | chosen |
[
{
"from": "system",
"value": "Change lifetime report to include active/inactive status\n"
},
{
"from": "human",
"value": "var genericLoader = require('./generic_report_loader');\n\nvar AGGREGATION_STEPS = [\n { $project: { instanceId: 1, date: 1, _id: 0 } },\n { $group: { _id: \"$instanceId\",... | javascript | chosen |
[
{
"from": "system",
"value": "Fix test for no-permission component\n"
},
{
"from": "human",
"value": "import { expect } from 'chai'\nimport { describe, it } from 'mocha'\nimport { setupComponentTest } from 'ember-mocha'\nimport hbs from 'htmlbars-inline-precompile'\nimport { find } from 'ember-n... | javascript | chosen |
[
{
"from": "system",
"value": "Increase the leak test timeout for CI\n"
},
{
"from": "human",
"value": "var ssr = require(\"../lib/\");\nvar helpers = require(\"./helpers\");\nvar assert = require(\"assert\");\nvar iterate = require(\"leakage\").iterate;\nvar path = require(\"path\");\nvar throug... | javascript | chosen |
[
{
"from": "system",
"value": "Fix angle of clocks hour indicator\n"
},
{
"from": "human",
"value": "/**\n * @module timed\n * @submodule timed-components\n * @public\n */\nimport Component from '@ember/component'\nimport moment from 'moment'\nimport Ember from 'ember'\nimport { task, timeout } f... | javascript | chosen |
[
{
"from": "system",
"value": "Fix deprecation image-loader warnings. Now each loader option must be passed to the correspondent optimizer.\n"
},
{
"from": "human",
"value": "const path = require('path')\n\nmodule.exports = {\n entry: ['babel-polyfill', './src/index.js'],\n output: {\n path:... | javascript | chosen |
[
{
"from": "system",
"value": "Support Cordova 7.0 file structure\n"
},
{
"from": "human",
"value": "module.exports = function(ctx) {\n var fs = ctx.requireCordovaModule('fs'),\n path = ctx.requireCordovaModule('path'),\n xml = ctx.requireCordovaModule('cordova-common').xmlHelper... | javascript | chosen |
[
{
"from": "system",
"value": "Make use of Sauce Connect during Travis tests.\n"
},
{
"from": "human",
"value": "exports.config = {\n framework: 'jasmine2',\n specs: ['spec.js'],\n}\n\nif (process.env.SAUCE_USERNAME && process.env.SAUCE_ACCESS_KEY) {\n exports.config.sauceUser = process.... | javascript | chosen |
[
{
"from": "system",
"value": "Add exception if file does not exists\n"
},
{
"from": "human",
"value": "var fs = require('fs');\nvar jsss = require('./jsss');\nvar argv = process.argv;\nvar message = require('./message');\nvar pkg = fs.readFileSync(__dirname + '/../package.json');\n\nif(argv[2] !... | javascript | chosen |
[
{
"from": "system",
"value": "Fix scrolling to first JavaScript error"
},
{
"from": "human",
"value": "require('@client-side-validations/client-side-validations')\nrequire('@client-side-validations/simple-form/dist/simple-form.bootstrap4')\n\nClientSideValidations.callbacks.form.fail = ($form, e... | javascript | chosen |
[
{
"from": "system",
"value": "Add new tests for isPingPong and revise tests for pingPong\n"
},
{
"from": "human",
"value": "describe('pingPong', function() {\n it(\"returns true for a number that is divisible by 3\", function() {\n expect(pingPong(6)).to.equal(true);\n });\n it(\"returns t... | javascript | chosen |
[
{
"from": "system",
"value": "Make getting back to dashboard instantaneous\n\nBy using an updated version of store.filter with forceReload turned on\nfor accounts, we can avoid waiting for any load when a user navigates\naway from the dashboard and then returns. A query to refresh data will\nbe still send i... | javascript | chosen |
[
{
"from": "system",
"value": "Remove locale related reassignment to global window object\n"
},
{
"from": "human",
"value": "import React from 'react';\nimport PropTypes from 'prop-types';\nimport getDisplayName from '../utils/getDisplayName';\nimport { localeShape } from '../constants/PropTypes'... | javascript | chosen |
[
{
"from": "system",
"value": ":art: Improve naming of CLI tests\n"
},
{
"from": "human",
"value": "var assert = require('assert'),\n should = require('should'),\n childProcess = require('child_process');\n\n\ndescribe('CLI', function () {\n describe('#help', function () {\n it('should ... | javascript | chosen |
[
{
"from": "system",
"value": "Use a named function instead via @hunterloftis\n"
},
{
"from": "human",
"value": "'use strict';\n\nlet cli = require('heroku-cli-util');\nlet request = require('request');\n\nmodule.exports = {\n topic: 'builds',\n command: 'output',\n needsAuth: true,\n nee... | javascript | chosen |
[
{
"from": "system",
"value": "Add bower and autoform packages"
},
{
"from": "human",
"value": "var yeoman = require('yeoman-generator')\n\nmodule.exports = yeoman.generators.Base.extend({\n app: function() {\n this.mkdir('client')\n this.mkdir('client/lib')\n this.mkdir('client/compati... | javascript | chosen |
[
{
"from": "system",
"value": "Update up to recent changes\n"
},
{
"from": "human",
"value": "// Single payment submitted view\n\n'use strict';\n\nvar documentView = require('./components/business-process-document')\n , renderDocumentHistory = require('./components/business-process-docu... | javascript | chosen |
[
{
"from": "system",
"value": "Fix object subkeys, make tests pass\n"
},
{
"from": "human",
"value": "/**\n * Filters out all duplicate items from an array by checking the specified key\n * @param [key] {string} the name of the attribute of each object to compare for uniqueness\n if the key is em... | javascript | chosen |
[
{
"from": "system",
"value": "Set a better format to errors and remove password when user created\n"
},
{
"from": "human",
"value": "const User = require('./../../models/user')\n\nconst usersRoutes = (api) => {\n api.post('/users', (req, res) => {\n User.create(req.body.user)\n .then((u... | javascript | chosen |
[
{
"from": "system",
"value": "Add more flexible entity filter function\n"
},
{
"from": "human",
"value": "/**\n * Created by faide on 4/21/2015.\n */\n\nexport default class Scene {\n constructor(id = `scene_${Date.now().toString()}`,\n entities = [], map = null) {\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Make a POST request to create a user.\n"
},
{
"from": "human",
"value": "{\n class UsersService {\n create(user) {\n console.log('CREATED!');\n console.log(user);\n }\n }\n\n angular.module('meganote.users')\n .service('UsersService', UsersServic... | javascript | chosen |
[
{
"from": "system",
"value": "Remove workaround for obsolete environments\n"
},
{
"from": "human",
"value": "/*!\n * Determine if an object is a Buffer\n *\n * @author Feross Aboukhadijeh <feross@feross.org> <http://feross.org>\n * @license MIT\n */\n\n// The _isBuffer check is for Safari 5-7... | javascript | chosen |
[
{
"from": "system",
"value": "refactor: Fix a hard coding of the configuration file name\n"
},
{
"from": "human",
"value": "#!/usr/bin/env node\n\nconst co = require('co');\nconst util = require('./lib/util');\nconst m = require('./lib/main');\nconst initCommand = require('./lib/init.cmd');\ncon... | javascript | chosen |
[
{
"from": "system",
"value": "Switch to arrow functions in a couple of places\n\nWe'll refactor further once we move this module to TypeScript.\n"
},
{
"from": "human",
"value": "const UINode = require('./lib/node');\n\nconst UIWindow = ObjC.classes.UIWindow;\n\nfunction get(predicate) {\n retu... | javascript | chosen |
[
{
"from": "system",
"value": "Disable rules covered by the TS compiler\n"
},
{
"from": "human",
"value": "module.exports = {\n extends: [\n require.resolve('./javascript'),\n 'plugin:@typescript-eslint/recommended',\n 'plugin:import/typescript',\n 'prettier/@typescript-eslint',\n ]... | javascript | chosen |
[
{
"from": "system",
"value": "Fix specifying loadSchema() function from webpack configuration\n\nObject.assign() assigns the properties to its first parameter, which results in ajvOptions immediately being overwritten with the defaults that are provided. The second time ajvOptions is passed, it has no effec... | javascript | chosen |
[
{
"from": "system",
"value": "Update to previous: debug logging removed\n"
},
{
"from": "human",
"value": "import knex from '../utils/db';\n\nconst lectureSummaryFields = ['id', 'createdAt', 'title', 'dates'];\nconst lectureDetailedFields = '*';\n\nexport const dbGetLectures = userId => (\n kne... | javascript | chosen |
[
{
"from": "system",
"value": "Use a simple foor loop instead of .find to avoid using a polyfill\n"
},
{
"from": "human",
"value": "/**\n * Export javascript style and css style vendor prefixes.\n * Based on \"transform\" support test.\n */\n\nimport isBrowser from 'is-browser'\n\nlet js = ''\nle... | javascript | chosen |
[
{
"from": "system",
"value": "ENYO-2987: Add library class to body.\n\nEnyo-DCO-1.1-Signed-off-by: Aaron Tam <aaron.tam@lge.com>\n"
},
{
"from": "human",
"value": "/**\n* Features a variety of commonly used widgets, including toolbars, text inputs, checkboxes, groups\n* and multiple types of but... | javascript | chosen |
[
{
"from": "system",
"value": "Fix bug when trying to deep extend a string\n\nThis adds another check to ensure `target[prop]` is an object. Otherwise `deepExtend` throws"
},
{
"from": "human",
"value": "export const deepExtend = function(target){\n for (var i = 1; i < arguments.length; i++) {\n... | javascript | chosen |
[
{
"from": "system",
"value": "Change the way the Remapping abstraction works\n\nSo that we can make Transform derive from it, and have a more unified\nway of representing mapping pipelines.\n"
},
{
"from": "human",
"value": "const {Remapping, Transform} = require(\"../transform\")\n\nfunction re... | javascript | chosen |
[
{
"from": "system",
"value": "Send data from the server\n"
},
{
"from": "human",
"value": "exports.init = function () {\n debugger\n}\n"
},
{
"from": "gpt",
"value": "exports.init = function () {\n};\n\nexports.clientConnectedServer = function (link) {\n setInterval(function ()... | javascript | chosen |
[
{
"from": "system",
"value": "Use implicit restrict and bindings\n\nAn angular component is restricted to elements (\"E\") by default.\n"
},
{
"from": "human",
"value": "import template from \"./login.html\";\nimport controller from \"./login.controller\";\nimport \"./login.styl\";\n\nlet loginC... | javascript | chosen |
[
{
"from": "system",
"value": "Fix for Expandables on Blog\n"
},
{
"from": "human",
"value": "/* ==========================================================================\n Common scripts that are used on old sheer templates\n These should be removed as templates are moved to wagtail\n ===... | javascript | chosen |
[
{
"from": "system",
"value": "Enable tunnel only through environment variable\n"
},
{
"from": "human",
"value": "module.exports = {\n // Minimal configuration needed\n 'SLACK_CLIENT_ID': process.env.SLACK_CLIENT_ID || 'YOUR_SLACK_CLIENT_ID',\n 'SLACK_SECRET': process.env.SLACK_SECRET || 'YOUR... | javascript | chosen |
[
{
"from": "system",
"value": "Use System.import until jest supports it\n"
},
{
"from": "human",
"value": "import Definition, { asyncComponent } from 'hippo/screens/definition';\nimport Group from 'hippo/screens/group';\n\n<% Hippo::Screen.each_group do | group | %>\nGroup.register( <%= group.to_... | javascript | chosen |
[
{
"from": "system",
"value": "Add route for records, i.e. all input data\n"
},
{
"from": "human",
"value": "'use strict';\n\n\n// Declare app level module which depends on filters, and services\nangular.module('myApp', [\n 'ngRoute',\n 'myApp.filters',\n 'myApp.services',\n 'myApp.directives... | javascript | chosen |
[
{
"from": "system",
"value": "Fix redirect bug for new users\n"
},
{
"from": "human",
"value": "var server = require('./server'),\n models = require('./models');\n\n/*\n * GET home page.\n */\n\nexports.index = function(req, res) {\n res.render('index', {\n title: 'SwiftCODE',\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Move searchPortal ref function to constructor\n\n- Fixes issue #666.\n"
},
{
"from": "human",
"value": "import React, { Component } from 'react';\n\nexport default class MentionSuggestionsPortal extends Component {\n\n // When inputting Japanese characters (or any ... | javascript | chosen |
[
{
"from": "system",
"value": "Handle PhantomJS child process errors\n"
},
{
"from": "human",
"value": "'use strict';\n\nvar app = require('./server/index');\nvar conf = require('./server/conf');\nvar logger = conf.logger;\nvar phantom = require('./server/phantom');\n\nif (!module.parent) {\n lo... | javascript | chosen |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.