This is my array for function
var funcArray = Array<() -> Void>()
To the array I append closure functions which comes as a parameter
func someFunc(completition: (() -> Void)?){
// ...
if let callback = completition {
funcArray.append(callback)
}
// ...
}
How can I check if the array already contains the function before appending it to the array ?