port fixed
final version done