Remove code unrelated to bug