Update darwin2p0.js

This should fix your problem and simplify the code some.