fixed return functionalit