reverted doubled code