conversations listlengths 2 3 | source stringclasses 1
value | stack stringclasses 1
value |
|---|---|---|
[
{
"from": "system",
"value": "Change all quotes to double for uniformity\n"
},
{
"from": "human",
"value": "/*jslint vars: true, plusplus: true, devel: true, nomen: true, regexp: true, indent: 4, maxerr: 50 */\n/*global define, $, brackets, window */\n\n/** Autosaves all files when leaving Brack... | javascript | chosen |
[
{
"from": "system",
"value": "Add userimports reducer to root reducer\n"
},
{
"from": "human",
"value": "import { combineReducers } from 'redux';\n\nimport authentication from 'reducers/app/authenticationReducer';\nimport confirmEmail from 'reducers/app/confirmEmailReducer';\nimport slideEditor ... | javascript | chosen |
[
{
"from": "system",
"value": "Remove minimum requirements for now until we can increase coverage\n"
},
{
"from": "human",
"value": "'use strict';\n\nmodule.exports = function(grunt) {\n\n grunt.initConfig({\n pkg: grunt.file.readJSON('package.json'),\n jshint: {\n all... | javascript | chosen |
[
{
"from": "system",
"value": "Update grunt file to perform coverage task\n"
},
{
"from": "human",
"value": "'use strict';\n\nmodule.exports = function(grunt) {\n\n grunt.initConfig({\n pkg: grunt.file.readJSON('package.json'),\n jshint: {\n allFiles: ['Gruntfile.js', ... | javascript | chosen |
[
{
"from": "system",
"value": "Add other files to jshint task\n\nAlso add ES6 support for JSHint\n"
},
{
"from": "human",
"value": "module.exports = function(grunt) {\n grunt.initConfig({\n pkg: grunt.file.readJSON('package.json'),\n\n bump: {\n options: {\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Add controller (to be filled out).\n"
},
{
"from": "human",
"value": "angular.module('materialscommons').component('mcExperimentNotes', {\n templateUrl: 'app/project/experiments/experiment/components/notes/mc-experiment-notes.html',\n bindings: {\n expe... | javascript | chosen |
[
{
"from": "system",
"value": "Fix retro compatibility in dynamodb model\n"
},
{
"from": "human",
"value": "const smash = require(\"../../smash.js\");\nconst logger = smash.logger(\"DynamodbModel\");\nconst DYNAMODB_TABLE_SUFFIX = \"dynamodb.tableSuffix\";\nconst UNDERSCORE = \"_\";\n\nclass Dyna... | javascript | chosen |
[
{
"from": "system",
"value": "Handle placeholder deletion before animation fallback\n"
},
{
"from": "human",
"value": "(function () {\nvar logoPath = '/customize/CryptPad_logo.svg';\nif (location.pathname === '/' || location.pathname === '/index.html') {\n logoPath = '/customize/CryptPad_logo... | javascript | chosen |
[
{
"from": "system",
"value": "Change to private test webhook\n"
},
{
"from": "human",
"value": "/*\n * Copyright (c) 2014-2021 Bjoern Kimminich.\n * SPDX-License-Identifier: MIT\n */\n\nconst chai = require('chai')\nconst expect = chai.expect\nconst chaiAsPromised = require('chai-as-promised')\n... | javascript | chosen |
[
{
"from": "system",
"value": "Load reports only if they aren't in rootScope\n"
},
{
"from": "human",
"value": "'use strict';\n\nangular.module('privateTheaterApp')\n .controller('AdminCtrl', ['$scope', '$rootScope', 'MediaError',function ($scope, $rootScope, MediaError) {\n $rootScope.report... | javascript | chosen |
[
{
"from": "system",
"value": "[FIX] Modify display style of points on team dashboard\n"
},
{
"from": "human",
"value": "import React from 'react';\nimport PropTypes from 'prop-types';\nimport { Spinner } from '@blueprintjs/core';\n\nimport '../../scss/views/_team-panel.scss';\n\n\nclass TeamPane... | javascript | chosen |
[
{
"from": "system",
"value": "Adjust initial state for auth\n"
},
{
"from": "human",
"value": "\n\nexport default {\n sources: [],\n articles: [],\n auth: {\n isAuthenticated: false,\n isAuthenticating: true,\n user_id: ''\n }\n}\n"
},
{
"from": "gpt",
"value": "\n... | javascript | chosen |
[
{
"from": "system",
"value": "Fix tests in the browser due to fixtures not loaded\n"
},
{
"from": "human",
"value": "const fs = require('fs'); // import syntax doesn't work inside karma\n\nconst fixtureNames = [\n\t'libraries.json',\n\t'library.json',\n\t'libraryVersions.json',\n\t'test-library-... | javascript | chosen |
[
{
"from": "system",
"value": "Return responses to introspect methods.\n"
},
{
"from": "human",
"value": "define(['exports', 'module'],\nfunction(exports, module) {\n\n exports = module.exports = function(caps) {\n \n var service = new Object();\n service.listMethods = function(result) {\... | javascript | chosen |
[
{
"from": "system",
"value": "Fix bug loading keys from process.env\n"
},
{
"from": "human",
"value": "const jwt = require('jsonwebtoken')\nconst axios = require('axios')\n\nconst CONTENT_TYPE = 'application/vnd.github.machine-man-preview+json'\n\n// the secret key and app id to create an encryp... | javascript | chosen |
[
{
"from": "system",
"value": "Add shim config for jquery expander plugin so we don't have intermittent JS errors about jQuery not being defined\n"
},
{
"from": "human",
"value": "// Common configuration for RequireJS\nvar require = {\n baseUrl: \"/scripts\",\n paths: {\n \"jquery\"... | javascript | chosen |
[
{
"from": "human",
"value": "test(issue): Add missing test for issue element.\n"
},
{
"from": "gpt",
"value": "describe('[issue/element]', function () {\n\tvar $rootScope, $compile, $templateCache,\n\t\tPullRequestListController, scope, element;\n\n\tbeforeEach(module('ed.issue'));\n\tbeforeEach... | javascript | chosen |
[
{
"from": "system",
"value": "Add a blank state in AnnotatorSelector\n"
},
{
"from": "human",
"value": "import React from 'react'\nimport PropTypes from 'prop-types'\nimport SelectableAnnotation from './selectable-annotation'\n\nexport default function Selector ({ annotations, onSelect }) {\n r... | javascript | chosen |
[
{
"from": "system",
"value": "Add balham theme to bundle\n"
},
{
"from": "human",
"value": "require('./dist/lib/main');\n\n// add in exports for ag-Grid-Enterprise\nvar agGridEnterprise = require('./main');\nObject.keys(agGridEnterprise).forEach(function(key) {\n exports[key] = agGridEnterpri... | javascript | chosen |
[
{
"from": "system",
"value": "Mark eslint-loader as \"pre\" loader, update extract-text-plugin option names\n"
},
{
"from": "human",
"value": "/**\n * @fileOverview Webpack basic configuration file.\n */\n\nconst ExtractTextPlugin = require('extract-text-webpack-plugin');\n\nmodule.exports = {\n... | javascript | chosen |
[
{
"from": "system",
"value": "Remove shift that was supposed to remove the callback only when it existed\n\nSigned-off-by: Henrique Vicente <d390f26e2f50ad5716a9c69c58de1f5df9730e3b@gmail.com>\n"
},
{
"from": "human",
"value": "/*\n * grunt-cli-config\n * https://github.com/henvic/grunt-cli-conf... | javascript | chosen |
[
{
"from": "system",
"value": "Use async in hydrater and remove tab\n"
},
{
"from": "human",
"value": "'use strict';\n\nvar fs = require('fs');\nvar config = require('../config/configuration.js');\nvar markdown = require('markdown').markdown;\n\n/**\n * Extract the content in html of the specifie... | javascript | chosen |
[
{
"from": "system",
"value": "Move helper functions inside 'interpret'\n"
},
{
"from": "human",
"value": "import match from './match';\nimport {matchOn} from './match';\n\n// Convert a free monad representation into a JSON representation\nconst process = (env, node) => matchOn('nodeName')(node)(... | javascript | chosen |
[
{
"from": "system",
"value": "Fix on review, use default value instead of checking\n"
},
{
"from": "human",
"value": "import { UPDATE_TRADING_OPTIONS } from '../_constants/ActionTypes';\nimport * as LiveData from '../_data/LiveData';\n\nexport const updateTradingOptions = (symbol, opts) => ({\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Fix alignment in FF browser\n"
},
{
"from": "human",
"value": "import vars from '../../styles/vars'\n\nexport default {\n container: {\n color: vars.textColorInverse,\n backgroundColor: 'transparent',\n display: 'flex',\n alignItems: 'center',\n text... | javascript | chosen |
[
{
"from": "system",
"value": "Set Default for Flash Theme in Storybook\n"
},
{
"from": "human",
"value": "import React from 'react';\nimport { storiesOf } from '@storybook/react';\nimport {\n text,\n number,\n select\n} from '@storybook/addon-knobs';\nimport { action } from '@storybook/addon-... | javascript | chosen |
[
{
"from": "system",
"value": "Add test reporting debug logging\n"
},
{
"from": "human",
"value": "var request = require('superagent');\n\nmodule.exports = {\n \"Load front page\": function(browser) {\n browser\n .url(\"http://localhost:44199\")\n .waitForElementVi... | javascript | chosen |
[
{
"from": "system",
"value": "Clean up piechart-test and add test for valueTextFormatter\n"
},
{
"from": "human",
"value": "'use strict';\n\nvar expect = require('chai').expect; \n\ndescribe('PieChart', function() {\n it('renders piechart', function() {\n var React = require('react/addons')... | javascript | chosen |
[
{
"from": "system",
"value": "Remove test cruft that is causing failures.\n"
},
{
"from": "human",
"value": "import { test , moduleForComponent } from 'appkit/tests/helpers/module-for';\nimport BayeuxStub from 'appkit/tests/helpers/bayeux-stub';\nimport PipedriveDealsComponent from 'appkit/compo... | javascript | chosen |
[
{
"from": "system",
"value": "Make sure uls plugin is available before running\n"
},
{
"from": "human",
"value": "$('.uls-trigger').uls({\n quickList: ['en', 'es', 'fr'],\n onSelect: (language) => {\n if (window.currentUser.id !== '') {\n $.post(`/update_locale/${language}`, () => {\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Add console log to debug message and sender\n"
},
{
"from": "human",
"value": "import config from '../../index';\nimport express from 'express';\nimport request from 'request';\n\nclass WebhookService {\n constructor () {};\n\n static tokenVerify (req, res) {\n ... | javascript | chosen |
[
{
"from": "system",
"value": "edit-message: Fix styling issue in 'Edit Message' title text.\n"
},
{
"from": "human",
"value": "/* @flow */\nimport React, { PureComponent } from 'react';\nimport { Text } from 'react-native';\n\nimport type { Context } from '../types';\n\ntype Props = {\n text: s... | javascript | chosen |
[
{
"from": "system",
"value": "Replace URLSearchParams with Edge/IE-compatible regex\n\nFix #589\n"
},
{
"from": "human",
"value": "/**\n * User login.\n *\n * This Source Code Form is subject to the terms of the Mozilla Public\n * License, v. 2.0. If a copy of the MPL was not distributed with th... | javascript | chosen |
[
{
"from": "system",
"value": "Fix rss feed for test with empty title\n"
},
{
"from": "human",
"value": "var assert = require('assert');\nvar parser = require('../');\n\nvar rss = '<rss><channel><title>Test</title>' +\n '<item><title>T1</title></item>ABC<item><title>T2</title></item></channel>... | javascript | chosen |
[
{
"from": "system",
"value": "Add ES6 fat arrow function\n"
},
{
"from": "human",
"value": "require('./fake-path-factory');\n\nangular\n.module('fake')\n.service('fake', [\n 'FakePath',\n function(FakePath) {\n return function(path) {\n return new FakePath(path);\n };\n }\n]);"
}... | javascript | chosen |
[
{
"from": "system",
"value": "Test for presence of version property.\n"
},
{
"from": "human",
"value": "var vows = require('vows');\nvar assert = require('assert');\nvar junction = require('junction');\nvar disco = require('junction-disco');\nvar util = require('util');\n\n\nvows.describe('Libra... | javascript | chosen |
[
{
"from": "system",
"value": "Remove \"x-powered-by\" header (for security)\n"
},
{
"from": "human",
"value": "/**\n\n server\n\n The backbone of the server module. In development, this runs proxied through\n BrowserSync server.\n\n @param {Object} options Options passed on to \"globals\"\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Make check for segment header more reliable\n"
},
{
"from": "human",
"value": "var utils = exports\n\nutils.segmentIsHeader = function(segment) {\n if (segment) {\n return segment.parsed.SegmentType === 'MSH'\n }\n return false\n}\n\nutils.segmentTypeIsHeader ... | javascript | chosen |
[
{
"from": "system",
"value": "fix(decox-react): Update component only when its props changed\n\nCurrently a wrapper renders always when `setState` is called\nso change to determine whether it needs to re-render or not in\n`shouldComponentUpdate`.\n"
},
{
"from": "human",
"value": "import { Compo... | javascript | chosen |
[
{
"from": "system",
"value": "Allow to define also a logger\n"
},
{
"from": "human",
"value": "const AssetsOptions = require('./AssetsOptions');\nconst MaxdomeErrorLogger = require('./MaxdomeErrorLogger');\nconst MaxdomeOptions = require('./MaxdomeOptions');\nconst RequestBuilder = require('@max... | javascript | chosen |
[
{
"from": "system",
"value": "Add some toggle vars in navbar directive\n"
},
{
"from": "human",
"value": "\"use strict\";\n\nangular.module('arethusa.core').directive('arethusaNavbar', function(configurator) {\n return {\n restrict: 'AE',\n scope: true,\n link: function(scope, element,... | javascript | chosen |
[
{
"from": "system",
"value": "fix(uninstall): Make sure to remove all required files when uninstalling\n"
},
{
"from": "human",
"value": "'use strict';\n\n// Package config\nvar packageConfig = require('../package.json');\n\n// Node utils\nvar cartridgeUtil = require('cartridge-module-util')(pac... | javascript | chosen |
[
{
"from": "system",
"value": "Stop appending / to the key when there is no path\n"
},
{
"from": "human",
"value": "'use strict';\n\nvar Uri = require('jsuri');\n\nchrome.runtime.onInstalled.addListener(function() {\n chrome.contextMenus.create({\n title: 'Save Page Fields',\n contexts: ['... | javascript | chosen |
[
{
"from": "system",
"value": "Fix ascii blink regex to match non blink command\n"
},
{
"from": "human",
"value": "'use strict';\n\nvar figlet = require('figlet');\nvar util = require('../../utilities');\n\nvar random_font = function() {\n var fonts = [\n 'Basic',\n 'Big',\n 'JS Stick L... | javascript | chosen |
[
{
"from": "system",
"value": "Fix lifecycle hooks in StoreWatchMixin\n"
},
{
"from": "human",
"value": "module.exports = function(React) {\n return function() {\n var storeNames = Array.prototype.slice.call(arguments);\n return {\n componentDidMount: function() {\n var flux =... | javascript | chosen |
[
{
"from": "system",
"value": "Add requirejs configuration and Javascript files\n"
},
{
"from": "human",
"value": "/*global module:false*/\nmodule.exports = function(grunt) {\n\n\n // Project configuration.\n grunt.initConfig({\n // Metadata.\n pkg: grunt.file.readJSON('package.json'),\n\... | javascript | chosen |
[
{
"from": "system",
"value": "Put checks in on the method params\n"
},
{
"from": "human",
"value": "Meteor.methods({\n \n editableJSON_update: function (collectionName, _id, action) {\n \n var Collection = Mongo.Collection.get(collectionName);\n var updated = 0;\n \n try {\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Include quantity in shopping list API route\n"
},
{
"from": "human",
"value": "/****************************************************\n* /path /shoppinglist\n* /params null\n* /brief Returns all items with quantity less than threshold\n*\n* /author Luke\n*... | javascript | chosen |
[
{
"from": "system",
"value": "Sort remove unecessary parametar default value\n"
},
{
"from": "human",
"value": "const sorter = function(direction, sortBy, thenBy, depth = 0, a, b) {\n const valA = sortBy(a);\n const valB = sortBy(b);\n\n if (valA === valB) {\n if (thenBy && thenBy.length >... | javascript | chosen |
[
{
"from": "system",
"value": "Fix remote post form on the Dummy app.\n"
},
{
"from": "human",
"value": "$(function(){\n var form = $('#new-remote-post');\n\n if(form.length > 0) {\n\n Bootsy.areas[0].editor.on('load', function(){\n form.hide();\n });\n\n $('a[href=\"#new-remote-p... | javascript | chosen |
[
{
"from": "system",
"value": "Add \"ignitionScriptUri\" to install-coreos schema\n"
},
{
"from": "human",
"value": "// Copyright 2016, EMC, Inc.\n/* jshint node: true */\n\n'use strict';\n\ndescribe(require('path').basename(__filename), function() {\n var schemaFileName = 'install-coreos.json... | javascript | chosen |
[
{
"from": "system",
"value": "Update marko example to hapi v17\n"
},
{
"from": "human",
"value": "'use strict';\n// Load modules\n\nconst Hapi = require('hapi');\nconst Vision = require('../..');\nconst Path = require('path');\nconst Marko = require('marko');\n\n\n// Declare internals\n\nconst i... | javascript | chosen |
[
{
"from": "system",
"value": "Use underscore, not microscore, in Meteor blaze"
},
{
"from": "human",
"value": "Package.describe({\n summary: \"Meteor UI Components framework\",\n internal: true\n});\n\nPackage.on_use(function (api) {\n api.export(['Blaze']);\n api.use('jquery'); // should be... | javascript | chosen |
[
{
"from": "system",
"value": "Fix menu component with new props\n"
},
{
"from": "human",
"value": "var React = require('react');\n\nvar MenuItem = React.createClass({\n propTypes: {\n active: React.PropTypes.bool,\n href: React.PropTypes.string,\n className: React... | javascript | chosen |
[
{
"from": "system",
"value": "Change req.host to req.hostname as per express warning.\n"
},
{
"from": "human",
"value": "function requiresLogin(req, res, next) {\n if (!req.session.account) {\n return res.redirect('/');\n }\n\n next();\n}\n\nfunction requiresLogout(req, res, next) {\n if ... | javascript | chosen |
[
{
"from": "system",
"value": "Move signon ahead of install for message ordering\n"
},
{
"from": "human",
"value": "/**\n * Copyright 2018 The Subscribe with Google Authors. All Rights Reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this fil... | javascript | chosen |
[
{
"from": "system",
"value": "Switch InstantShare test to use Sinon infrastructure as per review comment\n"
},
{
"from": "human",
"value": "/* global sinon, Event, InstantShareApp */\n\ndescribe(\"InstantShareApp\", function() {\n \"use strict\";\n\n var sandbox, xhr;\n\n beforeEach(function(... | javascript | chosen |
[
{
"from": "system",
"value": "Adjust syntax to match records"
},
{
"from": "human",
"value": "'use strict'\n\nconst tokens = require('../database/tokens')\nconst KnownError = require('../utils/KnownError')\n\nconst response = (entry) => ({\n\tid: entry.id,\n\tcreated: entry.created,\n\tupdated: ... | javascript | chosen |
[
{
"from": "system",
"value": "Test style didn't apply to others\n"
},
{
"from": "human",
"value": "describe('Pseudo App Tests', () => {\n var App = require('../src/PseudoTestApp.js');\n var React = require('react');\n var ReactDOM = require('react-dom');\n var TestUtils = require('re... | javascript | chosen |
[
{
"from": "system",
"value": "Remove non-needed merge when setting Listener component state "
},
{
"from": "human",
"value": "const React = require(\"react\")\nconst {merge} = require(\"./util\")\n\nexport class Listener extends React.Component {\n constructor(props) {\n super(props)\n co... | javascript | chosen |
[
{
"from": "system",
"value": "Add Pause keycode for androidtv remote\n"
},
{
"from": "human",
"value": "if (navigator.userAgent.indexOf('Android') >= 0) {\n\tlog = console.log.bind(console)\n\n\tlog(\"Android detected\")\n\texports.core.vendor = \"google\"\n\texports.core.device = 2\n\texports.c... | javascript | chosen |
[
{
"from": "system",
"value": "Fix bug with attempting to handle a platform while building another one\n"
},
{
"from": "human",
"value": "var ios_script = require('./create_ios_strings');\nvar android_script = require('./create_android_strings');\n\nmodule.exports = function(context) {\n var Q... | javascript | chosen |
[
{
"from": "system",
"value": "Support async functions in tests\n"
},
{
"from": "human",
"value": "require('babel-core/register');\n\n// add a __rootdir global to avoid '../../../../../'\n// like paths when requiring package files.\nvar path = require('path');\n__rootdir = path.resolve(__dirname,... | javascript | chosen |
[
{
"from": "system",
"value": "Move DOMURL into browserImageSize function\n\nAllows isomorphic code to require browser-image-size\nCalling browserImageSize will still throw an error\n"
},
{
"from": "human",
"value": "/* istanbul ignore next */\nvar DOMURL = require('object-url')\n\n/**\n * Get an... | javascript | chosen |
[
{
"from": "system",
"value": "Print error stacktrace when promise fails\n"
},
{
"from": "human",
"value": "var winston = require('winston');\n\nfunction failedPromiseHandler(logger) {\n logger = logger || winston;\n\n return function(err) {\n logger.error(err);\n };\n}\n\nmodule.exports = ... | javascript | chosen |
[
{
"from": "system",
"value": "Remove whitespace from top of file\n\nRemove the unnecessary space at the top of the file before\nthe first code declaration.\n"
},
{
"from": "human",
"value": "\nvar valid = function(el) {\n // jquery the selector\n var $el = $(el);\n // narrow selection to only... | javascript | chosen |
[
{
"from": "system",
"value": "Add node: for internal modules\n"
},
{
"from": "human",
"value": "'use strict';\n\nconst fs = require('fs');\n\n// Print specified line from a file\n// fileName - string, file to parse\n// lineNumber - number, line starting from 1\n// Returns: boolean, success s... | javascript | chosen |
[
{
"from": "system",
"value": "Resolve race condition in tests by keeping event loop alive\n\nAdd a dummy setTimeout() call that keeps the event loop alive\nlong enough to receive signals.\nThere may be better ways to do this, but this is simple and seems\nsufficiently reliable.\n"
},
{
"from": "huma... | javascript | chosen |
[
{
"from": "system",
"value": "Fix - Mongoose Promise Deprecation warning\n"
},
{
"from": "human",
"value": "import mongoose from 'mongoose'\nimport grid from 'gridfs-stream'\nimport { log } from './'\n\nconst dbHost = process.env.DB_HOST || 'localhost'\nconst dbName = process.env.DB_NAME || 'muf... | javascript | chosen |
[
{
"from": "system",
"value": "Update jest-puppeteer server port to match webpack-dev-server\n"
},
{
"from": "human",
"value": "module.exports = {\n launch: {\n headless: process.env.CI === 'true',\n },\n server: {\n command: 'npm start',\n port: 8080,\n },\n}"
... | javascript | chosen |
[
{
"from": "system",
"value": "[fix] HTTP: Handle null request bodies properly\n"
},
{
"from": "human",
"value": "export function request(method, url, body, params = {}) {\n\tmethod = method.toUpperCase();\n\tif (typeof body === \"object\") {\n\t\tlet formstring = \"\";\n\t\tfor (let entry of bod... | javascript | chosen |
[
{
"from": "system",
"value": "Fix headers and compression issues\n"
},
{
"from": "human",
"value": "'use strict';\n\nvar config = require('meanio').loadConfig(),\n apiUri = config.api.uri,\n request = require('request');\n\nmodule.exports = function(General, app, auth, database) {\n app.get('... | javascript | chosen |
[
{
"from": "system",
"value": "Disable profile complete check for user tags\n"
},
{
"from": "human",
"value": "preloadSubscriptions.push('usertags');\n\n// Add our template to user profile viewing.\nuserProfileDisplay.push({template: \"listUserTags\", order: 2});\n// Add our template to user prof... | javascript | chosen |
[
{
"from": "system",
"value": "Add option for no ajax\n"
},
{
"from": "human",
"value": "/*\n FormAjaxifier\n @author Jeevan@blacklizard\n*/\n\n(function ($) {\n\n $.fn.FormAjaxifier = function (options) {\n\n var settings = $.extend({\n beforeSend: function (self) {},\... | javascript | chosen |
[
{
"from": "system",
"value": "Move host URL into env config\n"
},
{
"from": "human",
"value": "import DS from 'ember-data';\nimport ENV from \"superhero/config/environment\";\n\nexport default DS.RESTAdapter.extend({\n host: 'http://gateway.marvel.com',\n namespace: 'v1/public',\n buildURL: f... | javascript | chosen |
[
{
"from": "system",
"value": "Fix issue link example comment\n"
},
{
"from": "human",
"value": "/*\n Create an issue link\n */\nmodule.exports = function (task, jira, grunt, callback) {\n\t'use strict';\n\n // ## Create an issue link between two issues ##\n // ### Takes ###\n //\n ... | javascript | chosen |
[
{
"from": "system",
"value": "[Glitch] Replace to `workbox-webpack-plugin` from `offline-plugin`\n\nPort 81e1cc5fece9a431c28ca648c2dd4b1b5f643f13 to glitch-soc\n\nSigned-off-by: Claire <82b964c50e9d1d222e48cf5046e6484a966a7b07@sitedethib.com>\n"
},
{
"from": "human",
"value": "import * as regist... | javascript | chosen |
[
{
"from": "system",
"value": "backend: Update logic on game controller\n"
},
{
"from": "human",
"value": "var inspect = require('eyes').inspector({ stream: null });\n\nmodule.exports = {\n\n index: function(req, res, next){\n var project_id = req.query.project_id;\n\n process.database.ga... | javascript | chosen |
[
{
"from": "system",
"value": "Update estimation query to use the new function.\n"
},
{
"from": "human",
"value": "var _ = require('underscore');\nvar $ = require('jquery');\nvar cdb = require('cartodb.js');\nvar errorParse = require('../../../../../helpers/error-parser');\n\nvar ESTIMATION_QUOTA... | javascript | chosen |
[
{
"from": "system",
"value": "Fix typo in GitRPCService.diff function\n"
},
{
"from": "human",
"value": "// Requires\nvar Q = require('q');\nvar _ = require('underscore');\n\n\nfunction toBase(num, base) {\n return Number(Number(num).toString(base));\n}\n\n\nfunction GitRPCService(repo) {\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Fix UNEXPECTED_FULL_TRACE env variable for emulated DOM\n\nIf the DOM is emulated, and the tests are running under node, then the\nenvironment variable UNEXPECTED_FULL_TRACE was ignored. This change\ntreats the variable equally - i.e. if `process` is also defined\nglobally, and... | javascript | chosen |
[
{
"from": "system",
"value": "Allow other hosts to access webpack server\n\nWithout this, it is difficult to test across networks, across devices, and between VMs."
},
{
"from": "human",
"value": "var webpack = require(\"webpack\");\nvar config = require(\"./webpack.client.js\");\n\nconfig.cache... | javascript | chosen |
[
{
"from": "system",
"value": "Set Devices as default view.\n"
},
{
"from": "human",
"value": "const routes = [\n {\n url: '#/',\n template: './routes/home/home.template.mustache',\n controller: './routes/home/home.controller',\n controllerAs: 'home'\n },\n {\n url: '#/login',\n... | javascript | chosen |
[
{
"from": "system",
"value": "Clean up image code in controller.js\n"
},
{
"from": "human",
"value": "'use strict';\n\n/* Controllers */\n\nvar potwControllers = angular.module('potwControllers', []);\nvar $baseVideoURL = \"//www.youtube.com/embed/\";\n\npotwControllers.controller('PlayerListCtr... | javascript | chosen |
[
{
"from": "system",
"value": "Add strict mode to support generation script\n"
},
{
"from": "human",
"value": "var fs = require('fs'),\n words = require('./');\n\nfs.writeFileSync('Supported-words.md',\n 'Supported Words:\\n' +\n '=================\\n' +\n '\\n' +\n '| word | polar... | javascript | chosen |
[
{
"from": "system",
"value": "Add margin right when caret is present\n"
},
{
"from": "human",
"value": "import React from 'react';\nimport Button from '../button/Button';\nimport PropTypes from 'prop-types';\nimport DropdownCaret from './DropdownCaret';\n\nconst DropdownButton = ({ hasCaret = fa... | javascript | chosen |
[
{
"from": "system",
"value": "Add tmp dir to protractor-sauce\n"
},
{
"from": "human",
"value": "var fs = require('fs');\nvar specs = JSON.parse(fs.readFileSync('tests/end2end/specs.json'));\n\nvar browser_capabilities = JSON.parse(process.env.SELENIUM_BROWSER_CAPABILITIES);\nbrowser_capabilitie... | javascript | chosen |
[
{
"from": "system",
"value": "[FEATURE] Set basic auth in headers upon login.\n"
},
{
"from": "human",
"value": "angular.module('publicApp').service('UserService', ['$http','$location', 'Base64', function($http, $location, Base64) {\n var user = {\n isLogged: false,\n username: '',\n\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Change GCSE default theme to empty\n"
},
{
"from": "human",
"value": "(function(google) {\n google.load('search', '1', {\n language: 'en',\n style: google.loader.themes.V2_DEFAULT\n });\n\n google.setOnLoadCallback(function() {\n var cx = '00085082433566... | javascript | chosen |
[
{
"from": "system",
"value": "Add for-loop to arrayToList to allow for array arguments of dynamic length\n"
},
{
"from": "human",
"value": "// Write a function arrayToList that builds up a data structure like the previous one when given [1, 2, 3] as argument, and write a listToArray function tha... | javascript | chosen |
[
{
"from": "system",
"value": "Remove reference to IP in test\n"
},
{
"from": "human",
"value": "const Broker = require('../index')\nconst { secureRandom, createConnection, newLogger, retryProtocol } = require('testHelpers')\n\ndescribe('Broker > FindGroupCoordinator', () => {\n let groupId, see... | javascript | chosen |
[
{
"from": "system",
"value": "chore(generator): Fix false positives from ESLint in template files\n"
},
{
"from": "human",
"value": "'use strict'\n\nmodule.exports = {\n parser: 'babel-eslint',\n\n extends: [\n '@strv/javascript/environments/nodejs/v8-3',\n '@strv/javascript/environments... | javascript | chosen |
[
{
"from": "system",
"value": "Use arrow functions whenver possible\n"
},
{
"from": "human",
"value": "(function () {\n function initTwinklingStars() {\n const devicePixelRatio = Math.min(window.devicePixelRatio, 3) || 1;\n\n particlesJS('stars', {\n particles: {\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Add getBackground function to class Page\n"
},
{
"from": "human",
"value": "\n\n// namespace \nvar GNOVEL = GNOVEL || {};\n\n(function() {\n\t\"use strict\";\n\n\t/**\n\t *\n\t * @class Page\n\t * @constructor\n\t * \n\t */\n\tvar Page = function() {\n\t\tthis._owne... | javascript | chosen |
[
{
"from": "system",
"value": "Allow Template.p.jst to be an object referenced by name\n"
},
{
"from": "human",
"value": "// go.components.templating\n// =========================\n// Components the client-side templates used in Go.\n\n(function(exports) {\n var maybeByName = go.utils.maybeByNam... | javascript | chosen |
[
{
"from": "system",
"value": "Fix broken my playlists dropdown\n"
},
{
"from": "human",
"value": "require('../../navbar.js');\nrequire('../../auth.js');\n\nimport { sendGoogleAnalyticsPageView,\n sendGoogleAnalyticsEvent } from '../../googleAnalytics.js';\n\n$('#myPlaylistsDropdown a').o... | javascript | chosen |
[
{
"from": "system",
"value": "Set unsupported ES6 features to false\n"
},
{
"from": "human",
"value": "module.exports = {\n 'env': {\n 'es6': true\n },\n 'ecmaFeatures': {\n 'arrowFunctions': true,\n 'blockBindings': true,\n 'classes': true,\n 'destructuring': true,\n 'forOf... | javascript | chosen |
[
{
"from": "system",
"value": "Refactor event collection and add some extra configs\n"
},
{
"from": "human",
"value": "define(['backbone', 'marionette', 'views/event/event'], function(Backbone, Marionette, EventView) {\n return Backbone.Marionette.CollectionView.extend({\n itemView: Eve... | javascript | chosen |
[
{
"from": "system",
"value": "JsMinify: Use DDG require to load the library on Beta\n"
},
{
"from": "human",
"value": "DDH.js_minify = DDH.js_minify || {};\n\n\"use strict\";\n\nDDH.js_minify.build = function(ops) {\n\n var shown = false;\n\n return {\n onShow: function() {\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Remove browserSync.stream() so that it's only executed in inject task to avoid conflicts\n"
},
{
"from": "human",
"value": "const gulp = require('gulp');\nconst browserSync = require('browser-sync');\n<% if (js === 'babel' || framework === 'react' && js === 'js') { ... | javascript | chosen |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.