<?php
$file = 'app/Controllers/Mahasiswa.php';
$content = file_get_contents($file);

$replacements = [
    "->where('pengaturan_key', 'pddikti_url')->first()['pengaturan_value']" => "->getValue('pddikti_url', '')",
    "->where('pengaturan_key', 'pddikti_username')->first()['pengaturan_value']" => "->getValue('pddikti_username', '')",
    "->where('pengaturan_key', 'pddikti_password')->first()['pengaturan_value']" => "->getValue('pddikti_password', '')"
];

$content = str_replace(array_keys($replacements), array_values($replacements), $content);

file_put_contents($file, $content);
echo "Mahasiswa.php updated.\n";
