Fix some real basic mistake and missing return

=.= andrew you said you checked already ??