Working on Bugfix
Refactoring

Old method seemed to cause too many problems, trying a new method.