Skip to content

Commit

Permalink
refactor(hapi): format code
Browse files Browse the repository at this point in the history
  • Loading branch information
Torresmorah committed Nov 2, 2022
1 parent a2a87f9 commit 74276c5
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions hapi/src/services/node.service.js
Original file line number Diff line number Diff line change
Expand Up @@ -92,16 +92,10 @@ const getNodeEnpoints = (node) => {
}

const getFormatNode = (node) => {
let type = node.node_type

if (!type) {
type = null
} else if (!Array.isArray(type)) {
type = [type]
}
const type = node.node_type

const formatNode = {
type: type,
type: type && !Array.isArray(type) ? [type] : type,
full: node.full ?? false,
location: node.location ?? {},
producer_id: node.producer_id
Expand Down

0 comments on commit 74276c5

Please sign in to comment.