Fix typo and missing declaration