Skip to content

Commit

Permalink
fix(lint): address linting issues
Browse files Browse the repository at this point in the history
  • Loading branch information
Arcath committed Mar 21, 2023
1 parent 2b36921 commit de4cc62
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions src/functions/address-object.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
/* eslint @typescript-eslint/no-explicit-any:off */

import type {DeepPartial} from '../types'
import {defaults} from './defaults'

/** Options passed to `addressObject` */
Expand Down Expand Up @@ -32,9 +31,9 @@ export const addressObject = <ObjectType extends {[key: string]: any}>(
) => {
const {seperator, fallback} = defaults(options, defaultOptions)

return address.split(seperator).reduce((object, key) => {
if (object[key]) {
return object[key]
return address.split(seperator).reduce((currentObject, key) => {
if (currentObject[key]) {
return currentObject[key]
}

if (fallback) return fallback
Expand Down

0 comments on commit de4cc62

Please sign in to comment.