Skip to content

Commit

Permalink
Shortened loadSetting() ↞ [auto-sync from kudoai/bravegpt]
Browse files Browse the repository at this point in the history
  • Loading branch information
adamlui authored and kudo-sync-bot committed May 24, 2023
1 parent dc09193 commit 101b179
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions chatgpt/bravegpt/bravegpt.user.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// ==UserScript==
// @name BraveGPT 🤖
// @version 2023.5.17.3
// @version 2023.5.23
// @author Adam Lui
// @namespace https://github.com/adamlui
// @description Adds ChatGPT answers to Brave Search sidebar (powered by GPT-4!)
Expand Down Expand Up @@ -115,9 +115,8 @@
function getUserscriptManager() {
try { return GM_info.scriptHandler } catch (error) { return 'other' }}

function loadSetting() {
var keys = [].slice.call(arguments)
keys.forEach(function(key) {
function loadSetting(...keys) {
keys.forEach(key => {
config[key] = GM_getValue(configKeyPrefix + key, false)
})}

Expand Down

0 comments on commit 101b179

Please sign in to comment.