Protect from TypeErrors