alien4u
02/13/2019, 9:25 PM=
and some not?battk
02/13/2019, 9:31 PMbattk
02/13/2019, 9:32 PMalien4u
02/13/2019, 9:32 PMbattk
02/13/2019, 9:33 PMbattk
02/13/2019, 9:33 PMbattk
02/13/2019, 9:34 PMjkabot
02/13/2019, 9:34 PMalien4u
02/13/2019, 9:35 PMjkabot
02/13/2019, 9:36 PMSince map builds a new array, using it when you aren't using the returned array is an anti-pattern; use forEach or for-of instead. Signs you shouldn't be using map: A) You're not using the array it returns, and/or B) You're not returning a value from the callback.https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/map#Description
battk
02/13/2019, 9:36 PMbattk
02/13/2019, 9:37 PMoSearch.filters =
oSearch.filters.map.......
battk
02/13/2019, 9:38 PMbattk
02/13/2019, 9:38 PMbattk
02/13/2019, 9:39 PMvar filters = oSearch.filters;
filters.map ....
oSearch.filters = filters
battk
02/13/2019, 9:41 PMalien4u
02/13/2019, 9:41 PMbattk
02/13/2019, 9:45 PMalien4u
02/13/2019, 9:48 PMbattk
02/13/2019, 9:51 PMbattk
02/13/2019, 9:51 PMbattk
02/13/2019, 9:52 PMjkabot
02/13/2019, 9:54 PMSince map builds a new array, using it when you aren't using the returned array is an anti-pattern; use forEach or for-of instead. Signs you shouldn't be using map: A) You're not using the array it returns, and/or B) You're not returning a value from the callback.
jkabot
02/13/2019, 9:54 PMalien4u
02/13/2019, 9:54 PMalien4u
02/13/2019, 9:56 PMbattk
02/13/2019, 10:00 PM