typing mistake was causing a bug