Add return-statement to example factory

Otherwise Angular cannot use the factory.