-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Tsify lib/storage #4499
Tsify lib/storage #4499
Conversation
// declarations." | ||
// Updating profanities to v3 requires ESM modules | ||
// eslint-disable-next-line @typescript-eslint/no-var-requires, unicorn/prefer-module | ||
const profanities = require('profanities'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure if there's another way to do this. I could not get any import
working.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
profanities is another lib we can't upgrade because of ESM, so... one day this will probably be ok.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yay
@@ -122,7 +128,7 @@ export class StorageS3 extends StorageBase { | |||
const subHashes = _.chain(data.Items).pluck('unique_subhash').pluck('S').value(); | |||
const fullHashes = _.chain(data.Items).pluck('full_hash').pluck('S').value(); | |||
for (let i = MIN_STORED_ID_LENGTH; i < hash.length - 1; i++) { | |||
let subHash = hash.substring(0, i); | |||
const subHash = hash.substring(0, i); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
woot
* Tsify lib/storage * Add @types/request * Fix get/post types * Better type solution
* Tsify lib/storage * Add @types/request * Fix get/post types * Better type solution
No description provided.