Fix buggy Document.ready? when referening Element