<commit_before><commit_msg>Create Edit.php<commit_after><?php

namespace Blog\Views\Content;
use Blog\Events;
use Blog\Views;

class Edit extends Views\View {
	
	public function __construct( Events\Dispatcher $dispatcher ) {
		parent::__construct( $dispatcher );
		$this->setTheme( 'admin' );
	}
	
	public function editingPost( Events\Event $event ) {
		$post	= $event->get( 'post' );
		$vars	= array(
			'csrf'		=> $event->get( 'editpost_csrf' ),
			'post_title'	=> $post->title,
			'post_body'	=> $post->raw,
			'post_summary'	=> $post->summary,
			'post_pub'	=> $post->published_at
		);
		$event->set( 'edit_form', $vars );
	}
}
{'fraction_non_alphanumeric': 0.179080824088748, 'fraction_numerical': 0.0, 'mean_word_length': 4.266666666666667, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 16, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1538911', 'n_tokens_mistral': 252, 'n_tokens_neox': 230, 'n_words': 45}