Powerline fix

Based on @Ahed91 's answer. Fix #6.