Small bug fixes

Fixed script running for AJAX requests, fixed (again) wrong namespace