Adding functional CheckFunction