Final Layer Bug Fix

-Finally fixed the layer bug.