diff --git a/src/observable/list/common.ts b/src/observable/list/common.ts index 8dbf7873..c67a841b 100644 --- a/src/observable/list/common.ts +++ b/src/observable/list/common.ts @@ -14,9 +14,10 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ +import {BaseObservableList} from "./BaseObservableList"; /* inline update of item in collection backed by array, without replacing the preexising item */ -export function findAndUpdateInArray(predicate, array, observable, updater) { +export function findAndUpdateInArray(predicate: (value: T) => boolean, array: T[], observable: BaseObservableList, updater: (value: T) => any | false) { const index = array.findIndex(predicate); if (index !== -1) { const value = array[index]; @@ -29,4 +30,4 @@ export function findAndUpdateInArray(predicate, array, observable, updater) { return true; } return false; -} \ No newline at end of file +}