the empty doc issue plus failing glueing fixed