Skip to content

Commit

Permalink
fix: ✏️ inline and make some code
Browse files Browse the repository at this point in the history
  • Loading branch information
chantouchsek committed Jan 26, 2023
1 parent f55988a commit 6ff84d1
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
5 changes: 3 additions & 2 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import Validator from './core/Validator'
// augment typings of Vue.js
import './vue'

export class AxiosHttp {
class AxiosHttp {
installed = false
parsedQs: IParseOptions = {
comma: true,
Expand All @@ -22,7 +22,7 @@ export class AxiosHttp {
const { $axios, errorProperty, parsedQs } = defaultOption
BaseService.$http = $axios
BaseService.$errorProperty = errorProperty || 'errors'
BaseService.$parsedQs = parsedQs || this.parsedQs
BaseService.$parsedQs = parsedQs
Vue.mixin({
beforeCreate() {
this.$options.$errors = {} as never
Expand All @@ -39,6 +39,7 @@ export class AxiosHttp {
})
}
}

export * from './util'
export type { ValidatorType }
export { Validator, BaseService }
Expand Down
2 changes: 1 addition & 1 deletion src/util/formData.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ export function hasFilesDeep(obj: any): boolean {
if (obj === null) return false
if (typeof obj === 'object') {
for (const key in obj) {
if (hasOwnProperty(obj, key) && isFile(obj[key])) return true
if (isFile(obj[key])) return true
}
}
if (isArray(obj)) {
Expand Down

0 comments on commit 6ff84d1

Please sign in to comment.