Javascript Replace Part Of Array Methods In Js