Skip to content

Commit

Permalink
lint (#779)
Browse files Browse the repository at this point in the history
  • Loading branch information
Neztore authored Feb 14, 2024
1 parent 1e80b2d commit 0d34711
Show file tree
Hide file tree
Showing 125 changed files with 236 additions and 236 deletions.
2 changes: 1 addition & 1 deletion lib/accountinformation/getUserSocialLinks.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ function getUserSocialLinks (userId, jar) {
return http({
url: `//accountinformation.roblox.com/v1/users/${userId}/promotion-channels`,
options: {
jar: jar,
jar,
resolveWithFullResponse: true
}
})
Expand Down
4 changes: 2 additions & 2 deletions lib/accountsettings/block.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ function block (jar, token, userId) {
url: `//accountsettings.roblox.com/v1/users/${userId}/block`,
options: {
method: 'POST',
jar: jar,
jar,
headers: {
'X-CSRF-TOKEN': token
},
Expand All @@ -51,7 +51,7 @@ function block (jar, token, userId) {

exports.func = function (args) {
const jar = args.jar
return getGeneralToken({ jar: jar })
return getGeneralToken({ jar })
.then(function (xcsrf) {
return block(jar, xcsrf, args.userId)
})
Expand Down
4 changes: 2 additions & 2 deletions lib/accountsettings/unblock.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ function unblock (jar, token, userId) {
url: `//accountsettings.roblox.com/v1/users/${userId}/unblock`,
options: {
method: 'POST',
jar: jar,
jar,
headers: {
'X-CSRF-TOKEN': token
},
Expand All @@ -51,7 +51,7 @@ function unblock (jar, token, userId) {

exports.func = function (args) {
const jar = args.jar
return getGeneralToken({ jar: jar })
return getGeneralToken({ jar })
.then(function (xcsrf) {
return unblock(jar, xcsrf, args.userId)
})
Expand Down
4 changes: 2 additions & 2 deletions lib/asset/deleteFromInventory.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ function deleteFromInventory (jar, assetId, xcsrf) {
method: 'POST',
resolveWithFullResponse: true,
body: `assetId=${assetId}`,
jar: jar,
jar,
headers: {
'X-CSRF-TOKEN': xcsrf,
'content-type': 'application/x-www-form-urlencoded; charset=UTF-8'
Expand Down Expand Up @@ -62,7 +62,7 @@ function deleteFromInventory (jar, assetId, xcsrf) {
// Define
exports.func = function (args) {
const jar = args.jar
return getGeneralToken({ jar: jar })
return getGeneralToken({ jar })
.then(function (xcsrf) {
return deleteFromInventory(jar, args.assetId, xcsrf)
})
Expand Down
2 changes: 1 addition & 1 deletion lib/asset/uploadAnimation.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ function upload (data, itemOptions, assetId, jar, token) {
options: {
resolveWithFullResponse: true,
method: 'POST',
jar: jar,
jar,
body: data,
headers: {
'X-CSRF-TOKEN': token,
Expand Down
6 changes: 3 additions & 3 deletions lib/asset/uploadItem.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,11 @@ function uploadItem (jar, file, name, assetType, groupId) {
return getVerification({
url: 'https://www.roblox.com/build/upload',
options: {
jar: jar
jar
}
}).then(function (ver) {
const data = {
name: name,
name,
assetTypeId: assetType,
groupId: groupId || '',
__RequestVerificationToken: ver.inputs.__RequestVerificationToken,
Expand All @@ -51,7 +51,7 @@ function uploadItem (jar, file, name, assetType, groupId) {
verification: ver.header,
formData: data,
resolveWithFullResponse: true,
jar: jar
jar
}
}).then(function (res) {
if (res.statusCode === 302) {
Expand Down
2 changes: 1 addition & 1 deletion lib/asset/uploadModel.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ function upload (data, itemOptions, assetId, jar, token) {
options: {
resolveWithFullResponse: true,
method: 'POST',
jar: jar,
jar,
body: data,
headers: {
'X-CSRF-TOKEN': token,
Expand Down
2 changes: 1 addition & 1 deletion lib/avatar/avatarRules.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ exports.func = (args) => {
url: '//avatar.roblox.com/v1/avatar-rules',
options: {
method: 'GET',
jar: jar,
jar,
followRedirect: false,
resolveWithFullResponse: true
}
Expand Down
2 changes: 1 addition & 1 deletion lib/avatar/getCurrentAvatar.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ exports.func = (args) => {
url: '//avatar.roblox.com/v1/avatar',
options: {
method: 'GET',
jar: jar,
jar,
followRedirect: false,
resolveWithFullResponse: true
}
Expand Down
2 changes: 1 addition & 1 deletion lib/avatar/getRecentItems.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ exports.func = (args) => {
url: '//avatar.roblox.com/v1/recent-items/' + listType + '/list',
options: {
method: 'GET',
jar: jar,
jar,
resolveWithFullResponse: true
}
}).then((res) => {
Expand Down
4 changes: 2 additions & 2 deletions lib/avatar/redrawAvatar.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ function redrawAvatar (jar, token) {
url: '//avatar.roblox.com/v1/avatar/redraw-thumbnail',
options: {
method: 'POST',
jar: jar,
jar,
headers: {
'X-CSRF-TOKEN': token
},
Expand All @@ -42,7 +42,7 @@ function redrawAvatar (jar, token) {
exports.func = (args) => {
const jar = args.jar

return getGeneralToken({ jar: jar }).then((xcsrf) => {
return getGeneralToken({ jar }).then((xcsrf) => {
return redrawAvatar(jar, xcsrf)
})
}
4 changes: 2 additions & 2 deletions lib/avatar/removeAssetId.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ function removeAssetId (assetId, jar, xcsrf) {
url: 'https://avatar.roblox.com/v1/avatar/assets/' + assetId + '/remove',
options: {
method: 'POST',
jar: jar,
jar,
headers: {
'X-CSRF-TOKEN': xcsrf
},
Expand All @@ -49,7 +49,7 @@ function removeAssetId (assetId, jar, xcsrf) {
exports.func = (args) => {
const jar = args.jar

return getGeneralToken({ jar: jar }).then((xcsrf) => {
return getGeneralToken({ jar }).then((xcsrf) => {
return removeAssetId(args.assetId, jar, xcsrf)
})
}
16 changes: 8 additions & 8 deletions lib/avatar/setAvatarBodyColors.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,17 +26,17 @@ const nextFunction = (jar, token, headColorId, torsoColorId, rightArmColorId, le
url: '//avatar.roblox.com/v1/avatar/set-body-colors',
options: {
method: 'POST',
jar: jar,
jar,
headers: {
'X-CSRF-TOKEN': token
},
json: {
headColorId: headColorId,
torsoColorId: torsoColorId,
rightArmColorId: rightArmColorId,
leftArmColorId: leftArmColorId,
rightLegColorId: rightLegColorId,
leftLegColorId: leftLegColorId
headColorId,
torsoColorId,
rightArmColorId,
leftArmColorId,
rightLegColorId,
leftLegColorId
},
resolveWithFullResponse: true
}
Expand All @@ -54,7 +54,7 @@ const nextFunction = (jar, token, headColorId, torsoColorId, rightArmColorId, le
exports.func = (args) => {
const jar = args.jar

return getGeneralToken({ jar: jar }).then((xcsrf) => {
return getGeneralToken({ jar }).then((xcsrf) => {
return nextFunction(jar, xcsrf, args.headColorId, args.torsoColorId, args.rightArmColorId, args.leftArmColorId, args.rightLegColorId, args.leftLegColorId)
})
}
16 changes: 8 additions & 8 deletions lib/avatar/setAvatarScales.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,17 +26,17 @@ const nextFunction = (jar, token, height, width, head, depth, proportion, bodyTy
url: '//avatar.roblox.com/v1/avatar/set-scales',
options: {
method: 'POST',
jar: jar,
jar,
headers: {
'X-CSRF-TOKEN': token
},
json: {
height: height,
width: width,
head: head,
depth: depth,
proportion: proportion,
bodyType: bodyType
height,
width,
head,
depth,
proportion,
bodyType
},
resolveWithFullResponse: true
}
Expand All @@ -54,7 +54,7 @@ const nextFunction = (jar, token, height, width, head, depth, proportion, bodyTy
exports.func = (args) => {
const jar = args.jar

return getGeneralToken({ jar: jar }).then((xcsrf) => {
return getGeneralToken({ jar }).then((xcsrf) => {
return nextFunction(jar, xcsrf, args.height, args.width, args.head, args.depth, args.proportion, args.bodyType)
})
}
4 changes: 2 additions & 2 deletions lib/avatar/setPlayerAvatarType.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ const nextFunction = (jar, token, avatarType) => {
url: '//avatar.roblox.com/v1/avatar/set-player-avatar-type',
options: {
method: 'POST',
jar: jar,
jar,
headers: {
'X-CSRF-TOKEN': token
},
Expand All @@ -44,7 +44,7 @@ const nextFunction = (jar, token, avatarType) => {
exports.func = (args) => {
const jar = args.jar

return getGeneralToken({ jar: jar }).then((xcsrf) => {
return getGeneralToken({ jar }).then((xcsrf) => {
return nextFunction(jar, xcsrf, args.avatarType)
})
}
6 changes: 3 additions & 3 deletions lib/avatar/setWearingAssets.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,12 @@ const nextFunction = (jar, token, assetIds) => {
url: '//avatar.roblox.com/v1/avatar/set-wearing-assets',
options: {
method: 'POST',
jar: jar,
jar,
headers: {
'X-CSRF-TOKEN': token
},
json: {
assetIds: assetIds
assetIds
},
resolveWithFullResponse: true
}
Expand All @@ -44,7 +44,7 @@ const nextFunction = (jar, token, assetIds) => {
exports.func = (args) => {
const jar = args.jar

return getGeneralToken({ jar: jar }).then((xcsrf) => {
return getGeneralToken({ jar }).then((xcsrf) => {
return nextFunction(jar, xcsrf, args.assetIds)
})
}
4 changes: 2 additions & 2 deletions lib/avatar/wearAssetId.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ function wearAssetId (assetId, jar, xcsrf) {
url: 'https://avatar.roblox.com/v1/avatar/assets/' + assetId + '/wear',
options: {
method: 'POST',
jar: jar,
jar,
headers: {
'X-CSRF-TOKEN': xcsrf
},
Expand All @@ -49,7 +49,7 @@ function wearAssetId (assetId, jar, xcsrf) {
exports.func = (args) => {
const jar = args.jar

return getGeneralToken({ jar: jar }).then((xcsrf) => {
return getGeneralToken({ jar }).then((xcsrf) => {
return wearAssetId(args.assetId, jar, xcsrf)
})
}
8 changes: 4 additions & 4 deletions lib/badges/updateBadgeInfo.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,15 +28,15 @@ const updateInfo = (id, name, desc, enabled, xcrsf, jar) => {
options: {
resolveWithFullResponse: true,
method: 'PATCH',
jar: jar,
jar,
headers: {
'Content-Type': 'application/json',
'X-CSRF-TOKEN': xcrsf
},
body: JSON.stringify({
name: name,
name,
description: desc,
enabled: enabled
enabled
})
}
}).then(res => {
Expand Down Expand Up @@ -75,6 +75,6 @@ exports.func = async (args) => {
const enabled = args.enabled || true
const jar = args.jar

const xcsrf = await getGeneralToken({ jar: jar })
const xcsrf = await getGeneralToken({ jar })
return updateInfo(args.badgeId, name, description, enabled, xcsrf, jar)
}
10 changes: 5 additions & 5 deletions lib/cache/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ const wrap = require('./wrap.js')
// Define
module.exports = {
new: newCache,
add: add,
clear: clear,
addIf: addIf,
get: get,
wrap: wrap
add,
clear,
addIf,
get,
wrap
}
2 changes: 1 addition & 1 deletion lib/cache/new.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ module.exports = function (types) {
const expireValue = type.expire
const permanent = expireValue === true
const expire = (permanent || expireValue === false ? 0 : expireValue)
cache[type.name] = { items: {}, expire: expire, refresh: type.refresh, permanent: permanent }
cache[type.name] = { items: {}, expire, refresh: type.refresh, permanent }
}
return cache
}
6 changes: 3 additions & 3 deletions lib/chat/addUsersToConversation.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,12 @@ function addUsersToConversation (conversationId, userIds, jar, token) {
url: '//chat.roblox.com/v2/add-to-conversation',
options: {
method: 'POST',
jar: jar,
jar,
headers: {
'X-CSRF-TOKEN': token
},
json: {
conversationId: conversationId,
conversationId,
participantUserIds: userIds
},
resolveWithFullResponse: true
Expand All @@ -55,7 +55,7 @@ function addUsersToConversation (conversationId, userIds, jar, token) {
exports.func = (args) => {
const jar = args.jar

return getGeneralToken({ jar: jar }).then((xcsrf) => {
return getGeneralToken({ jar }).then((xcsrf) => {
return addUsersToConversation(args.conversationId, args.userIds, jar, xcsrf)
})
}
2 changes: 1 addition & 1 deletion lib/chat/chatSettings.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ exports.func = (args) => {
url: '//chat.roblox.com/v2/chat-settings',
options: {
method: 'GET',
jar: jar,
jar,
resolveWithFullResponse: true
}
}).then((res) => {
Expand Down
2 changes: 1 addition & 1 deletion lib/chat/getChatMessages.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ exports.func = (args) => {
url: '//chat.roblox.com/v2/get-messages?conversationId=' + conversationId + '&pageSize=' + pageSize + '&exclusiveStartMessageId=' + startMessageId,
options: {
method: 'GET',
jar: jar,
jar,
resolveWithFullResponse: true
}
}).then((res) => {
Expand Down
2 changes: 1 addition & 1 deletion lib/chat/getConversations.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ exports.func = (args) => {
url: '//chat.roblox.com/v2/get-conversations?conversationIds=' + conversationIds.join('&conversationIds='),
options: {
method: 'GET',
jar: jar,
jar,
resolveWithFullResponse: true
}
}).then((res) => {
Expand Down
Loading

0 comments on commit 0d34711

Please sign in to comment.