crashing bug fixed because of wrong aligning