Semi-working, prerewrite