No longer enrich suggestions
parent
0e61d8e330
commit
05a377a48a
|
@ -15,20 +15,6 @@ export const bodyNodes = (ast, suggestions: Suggestion[]): Body[] => {
|
||||||
return []
|
return []
|
||||||
}
|
}
|
||||||
|
|
||||||
const enrichedSuggestions = suggestions.map(s => {
|
|
||||||
if (s.name === funcNames.JOIN) {
|
|
||||||
return {
|
|
||||||
...s,
|
|
||||||
params: {
|
|
||||||
tables: 'object',
|
|
||||||
on: 'array',
|
|
||||||
fn: 'function',
|
|
||||||
},
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return s
|
|
||||||
})
|
|
||||||
|
|
||||||
const walker = new Walker(ast)
|
const walker = new Walker(ast)
|
||||||
|
|
||||||
const body = walker.body.map(b => {
|
const body = walker.body.map(b => {
|
||||||
|
@ -43,7 +29,7 @@ export const bodyNodes = (ast, suggestions: Suggestion[]): Body[] => {
|
||||||
return {
|
return {
|
||||||
...d,
|
...d,
|
||||||
id: uuid.v4(),
|
id: uuid.v4(),
|
||||||
funcs: functions(d.funcs, enrichedSuggestions),
|
funcs: functions(d.funcs, suggestions),
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
|
@ -54,7 +40,7 @@ export const bodyNodes = (ast, suggestions: Suggestion[]): Body[] => {
|
||||||
|
|
||||||
return {
|
return {
|
||||||
id,
|
id,
|
||||||
funcs: functions(funcs, enrichedSuggestions),
|
funcs: functions(funcs, suggestions),
|
||||||
declarations: [],
|
declarations: [],
|
||||||
type,
|
type,
|
||||||
source,
|
source,
|
||||||
|
|
Loading…
Reference in New Issue